From 711e8b09793a8c10a5e752de98ab05821039e623 Mon Sep 17 00:00:00 2001 From: danmx Date: Sat, 18 Apr 2020 16:53:24 +0200 Subject: [PATCH] delete(doc): manual pages Signed-off-by: danmx --- cmd/gendoc.go | 45 -------------------------- docs/README.md | 1 - docs/man/sigil.md | 28 ---------------- docs/man/sigil_list.md | 67 --------------------------------------- docs/man/sigil_session.md | 42 ------------------------ docs/man/sigil_ssh.md | 40 ----------------------- docs/man/sigil_verify.md | 35 -------------------- 7 files changed, 258 deletions(-) delete mode 100644 cmd/gendoc.go delete mode 100644 docs/man/sigil.md delete mode 100644 docs/man/sigil_list.md delete mode 100644 docs/man/sigil_session.md delete mode 100644 docs/man/sigil_ssh.md delete mode 100644 docs/man/sigil_verify.md diff --git a/cmd/gendoc.go b/cmd/gendoc.go deleted file mode 100644 index 7a7440d..0000000 --- a/cmd/gendoc.go +++ /dev/null @@ -1,45 +0,0 @@ -// +build ignore - -package cmd - -import ( - "os" - "path" - - log "github.com/sirupsen/logrus" - "github.com/spf13/cobra" - "github.com/spf13/cobra/doc" -) - -var ( - outDir = path.Join("docs", "man") - - // genDocCmd represents the gendoc command - genDocCmd = &cobra.Command{ - Use: "gendoc", - Short: "Generate the documentation in Markdown", - RunE: func(cmd *cobra.Command, args []string) error { - dir, err := os.Getwd() - if err != nil { - return err - } - docDir := path.Join(dir, outDir) - log.WithFields(log.Fields{ - "docDir": docDir, - "output-dir": cfg.GetString("output-dir"), - }).Debug("Path to the documentation") - if err = doc.GenMarkdownTree(rootCmd, docDir); err != nil { - return err - } - return nil - }, - TraverseChildren: false, - DisableAutoGenTag: true, - } -) - -func init() { - rootCmd.AddCommand(genDocCmd) - - genDocCmd.Flags().StringVar(&outDir, "output-dir", outDir, "specify output directory") -} diff --git a/docs/README.md b/docs/README.md index e267049..1e7ddf5 100644 --- a/docs/README.md +++ b/docs/README.md @@ -3,4 +3,3 @@ - [get started](00-get-started.md) - [configuration](10-configuration.md) - [usage](usage/README.md) -- [man pages](man/sigil.md) diff --git a/docs/man/sigil.md b/docs/man/sigil.md deleted file mode 100644 index 514d90a..0000000 --- a/docs/man/sigil.md +++ /dev/null @@ -1,28 +0,0 @@ -## sigil - -AWS SSM Session manager client - -### Synopsis - -A tool for establishing a session in EC2 instances with AWS SSM Agent installed - -### Options - -``` - -c, --config string full config file path - -p, --config-profile string pick the config profile (default "default") - --config-type string specify the type of a config file: json, yaml, toml, hcl, props (default "toml") - -h, --help help for sigil - --log-level string specify the log level: trace/debug/info/warn/error/fatal/panic (default "panic") - -m, --mfa string specify MFA token - --profile string specify AWS profile - -r, --region string specify AWS region -``` - -### SEE ALSO - -* [sigil list](sigil_list.md) - List available EC2 instances or SSM sessions -* [sigil session](sigil_session.md) - Start a session -* [sigil ssh](sigil_ssh.md) - Start ssh session -* [sigil verify](sigil_verify.md) - Verify if all external dependencies are available - diff --git a/docs/man/sigil_list.md b/docs/man/sigil_list.md deleted file mode 100644 index 1794c34..0000000 --- a/docs/man/sigil_list.md +++ /dev/null @@ -1,67 +0,0 @@ -## sigil list - -List available EC2 instances or SSM sessions - -### Synopsis - -Show list of all EC2 instances with AWS SSM Agent running or active SSM sessions. - -Supported groups of filters: -- instances: - - tags - list of tag keys with a list of values for given keys - - ids - list of instastance ids -- sessions: - - after - the timestamp, in ISO-8601 Extended format, to see sessions that started after given date - - before - the timestamp, in ISO-8601 Extended format, to see sessions that started before given date - - target - an instance to which session connections have been made - - owner - an AWS user account to see a list of sessions started by that user - -Filter format examples: -[default.filters.session] - after="2018-08-29T00:00:00Z" - before="2019-08-29T00:00:00Z" - target="i-xxxxxxxxxxxxxxxx1" - owner="user@example.com" -[default.filters.instance] - ids=["i-xxxxxxxxxxxxxxxx1","i-xxxxxxxxxxxxxxxx2"] - tags=[{key="Name",values=["WebApp1","WebApp2"]}] - - -``` -sigil list [flags] -``` - -### Examples - -``` -sigil list --output-format wide --instance-tags '[{"key":"Name","values":["Web","DB"]}]' -``` - -### Options - -``` - -h, --help help for list - --instance-ids strings specify instance ids to limit results - --instance-tags string specify instance tags, in JSON format, to limit results - -i, --interactive pick an instance or a session from a list and start or terminate the session - --output-format string specify output format: text/wide/json/yaml (default "text") - --session-filters stringToString specify session filters to limit results (default [after=,before=,target=,owner=]) - -t, --type string specify list type: instances/sessions (default "instances") -``` - -### Options inherited from parent commands - -``` - -c, --config string full config file path - -p, --config-profile string pick the config profile (default "default") - --config-type string specify the type of a config file: json, yaml, toml, hcl, props (default "toml") - --log-level string specify the log level: trace/debug/info/warn/error/fatal/panic (default "panic") - -m, --mfa string specify MFA token - --profile string specify AWS profile - -r, --region string specify AWS region -``` - -### SEE ALSO - -* [sigil](sigil.md) - AWS SSM Session manager client - diff --git a/docs/man/sigil_session.md b/docs/man/sigil_session.md deleted file mode 100644 index 365b440..0000000 --- a/docs/man/sigil_session.md +++ /dev/null @@ -1,42 +0,0 @@ -## sigil session - -Start a session - -### Synopsis - -Start a new session in chosen EC2 instance. - -``` -sigil session [flags] -``` - -### Examples - -``` -sigil session --type instance-id --target i-xxxxxxxxxxxxxxxxx -``` - -### Options - -``` - -h, --help help for session - --target string specify the target depending on the type - --type string specify target type: instance-id/private-dns/name (default "instance-id") -``` - -### Options inherited from parent commands - -``` - -c, --config string full config file path - -p, --config-profile string pick the config profile (default "default") - --config-type string specify the type of a config file: json, yaml, toml, hcl, props (default "toml") - --log-level string specify the log level: trace/debug/info/warn/error/fatal/panic (default "panic") - -m, --mfa string specify MFA token - --profile string specify AWS profile - -r, --region string specify AWS region -``` - -### SEE ALSO - -* [sigil](sigil.md) - AWS SSM Session manager client - diff --git a/docs/man/sigil_ssh.md b/docs/man/sigil_ssh.md deleted file mode 100644 index f7e3cb9..0000000 --- a/docs/man/sigil_ssh.md +++ /dev/null @@ -1,40 +0,0 @@ -## sigil ssh - -Start ssh session - -### Synopsis - -Start a new ssh for chosen EC2 instance. - -``` -sigil ssh [flags] -``` - -### Options - -``` - --gen-key-pair generate a temporary key pair that will be send and used. Use ${HOME}/.sigil/temp_key as an identity file - -h, --help help for ssh - --os-user string specify an instance OS user which will be using sent public key (default "ec2-user") - --port uint specify ssh port (default 22) - --pub-key string local public key that will be send to the instance, ignored when gen-key-pair is true - --target string specify the target depending on the type - --type string specify target type: instance-id/private-dns/name (default "instance-id") -``` - -### Options inherited from parent commands - -``` - -c, --config string full config file path - -p, --config-profile string pick the config profile (default "default") - --config-type string specify the type of a config file: json, yaml, toml, hcl, props (default "toml") - --log-level string specify the log level: trace/debug/info/warn/error/fatal/panic (default "panic") - -m, --mfa string specify MFA token - --profile string specify AWS profile - -r, --region string specify AWS region -``` - -### SEE ALSO - -* [sigil](sigil.md) - AWS SSM Session manager client - diff --git a/docs/man/sigil_verify.md b/docs/man/sigil_verify.md deleted file mode 100644 index 9663135..0000000 --- a/docs/man/sigil_verify.md +++ /dev/null @@ -1,35 +0,0 @@ -## sigil verify - -Verify if all external dependencies are available - -### Synopsis - -This command will check if all dependecies are installed. -Plugin documentation: https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-install-plugin.html - -``` -sigil verify -``` - -### Options - -``` - -h, --help help for verify -``` - -### Options inherited from parent commands - -``` - -c, --config string full config file path - -p, --config-profile string pick the config profile (default "default") - --config-type string specify the type of a config file: json, yaml, toml, hcl, props (default "toml") - --log-level string specify the log level: trace/debug/info/warn/error/fatal/panic (default "panic") - -m, --mfa string specify MFA token - --profile string specify AWS profile - -r, --region string specify AWS region -``` - -### SEE ALSO - -* [sigil](sigil.md) - AWS SSM Session manager client -