Skip to content

Commit

Permalink
Expose --event-log-file to render, apply, and test (#5828)
Browse files Browse the repository at this point in the history
* Expose --event-log-file and --enable-rpc to render, apply, test

* hack/generate-man.sh

* hide --event-log-file and regen man pages
  • Loading branch information
briandealwis authored May 13, 2021
1 parent 6d66d85 commit ffb7d2b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 deletions.
5 changes: 3 additions & 2 deletions cmd/skaffold/app/cmd/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,16 +165,17 @@ var flagRegistry = []Flag{
"debug": true,
},
FlagAddMethod: "BoolVar",
DefinedOn: []string{"dev", "build", "run", "debug", "deploy"},
DefinedOn: []string{"dev", "build", "run", "debug", "deploy", "render", "apply", "test"},
IsEnum: true,
},
{
Name: "event-log-file",
Usage: "Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true",
Hidden: true,
Value: &opts.EventLogFile,
DefValue: "",
FlagAddMethod: "StringVar",
DefinedOn: []string{"dev", "build", "run", "debug", "deploy"},
DefinedOn: []string{"dev", "build", "run", "debug", "deploy", "render", "test", "apply"},
},
{
Name: "rpc-port",
Expand Down
16 changes: 6 additions & 10 deletions docs/content/en/docs/references/cli/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ Examples:
Options:
-c, --config='': File for global configurations (defaults to $HOME/.skaffold/config)
--enable-rpc=false: Enable gRPC for exposing Skaffold events
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--force=false: Recreate Kubernetes resources if necessary for deployment, warning: might cause downtime!
--kube-context='': Deploy to this Kubernetes context
Expand All @@ -143,6 +144,7 @@ Use "skaffold options" for a list of global command-line options (applies to all
Env vars:

* `SKAFFOLD_CONFIG` (same as `--config`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_FORCE` (same as `--force`)
* `SKAFFOLD_KUBE_CONTEXT` (same as `--kube-context`)
Expand Down Expand Up @@ -191,7 +193,6 @@ Options:
--detect-minikube=true: Use heuristics to detect a minikube cluster
--dry-run=false: Don't build images, just compute the tag for each artifact.
--enable-rpc=false: Enable gRPC for exposing Skaffold events
--event-log-file='': Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true
--file-output='': Filename to write build images to
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--insecure-registry=[]: Target registries for built images which are not secure
Expand Down Expand Up @@ -230,7 +231,6 @@ Env vars:
* `SKAFFOLD_DETECT_MINIKUBE` (same as `--detect-minikube`)
* `SKAFFOLD_DRY_RUN` (same as `--dry-run`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_EVENT_LOG_FILE` (same as `--event-log-file`)
* `SKAFFOLD_FILE_OUTPUT` (same as `--file-output`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_INSECURE_REGISTRY` (same as `--insecure-registry`)
Expand Down Expand Up @@ -418,7 +418,6 @@ Options:
-d, --default-repo='': Default repository value (overrides global config)
--detect-minikube=true: Use heuristics to detect a minikube cluster
--enable-rpc=true: Enable gRPC for exposing Skaffold events
--event-log-file='': Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--force=false: Recreate Kubernetes resources if necessary for deployment, warning: might cause downtime!
--insecure-registry=[]: Target registries for built images which are not secure
Expand Down Expand Up @@ -471,7 +470,6 @@ Env vars:
* `SKAFFOLD_DEFAULT_REPO` (same as `--default-repo`)
* `SKAFFOLD_DETECT_MINIKUBE` (same as `--detect-minikube`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_EVENT_LOG_FILE` (same as `--event-log-file`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_FORCE` (same as `--force`)
* `SKAFFOLD_INSECURE_REGISTRY` (same as `--insecure-registry`)
Expand Down Expand Up @@ -570,7 +568,6 @@ Options:
-d, --default-repo='': Default repository value (overrides global config)
--detect-minikube=true: Use heuristics to detect a minikube cluster
--enable-rpc=false: Enable gRPC for exposing Skaffold events
--event-log-file='': Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--force=false: Recreate Kubernetes resources if necessary for deployment, warning: might cause downtime!
-i, --images=: A list of pre-built images to deploy
Expand Down Expand Up @@ -611,7 +608,6 @@ Env vars:
* `SKAFFOLD_DEFAULT_REPO` (same as `--default-repo`)
* `SKAFFOLD_DETECT_MINIKUBE` (same as `--detect-minikube`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_EVENT_LOG_FILE` (same as `--event-log-file`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_FORCE` (same as `--force`)
* `SKAFFOLD_IMAGES` (same as `--images`)
Expand Down Expand Up @@ -659,7 +655,6 @@ Options:
--detect-minikube=true: Use heuristics to detect a minikube cluster
--digest-source='remote': Set to 'remote' to skip builds and resolve the digest of images by tag from the remote registry. Set to 'local' to build images locally and use digests from built images. Set to 'tag' to use tags directly from the build. Set to 'none' to use tags directly from the Kubernetes manifests.
--enable-rpc=true: Enable gRPC for exposing Skaffold events
--event-log-file='': Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--force=false: Recreate Kubernetes resources if necessary for deployment, warning: might cause downtime!
--insecure-registry=[]: Target registries for built images which are not secure
Expand Down Expand Up @@ -713,7 +708,6 @@ Env vars:
* `SKAFFOLD_DETECT_MINIKUBE` (same as `--detect-minikube`)
* `SKAFFOLD_DIGEST_SOURCE` (same as `--digest-source`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_EVENT_LOG_FILE` (same as `--event-log-file`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_FORCE` (same as `--force`)
* `SKAFFOLD_INSECURE_REGISTRY` (same as `--insecure-registry`)
Expand Down Expand Up @@ -894,6 +888,7 @@ Options:
--cache-artifacts=true: Set to false to disable default caching of artifacts
-d, --default-repo='': Default repository value (overrides global config)
--digest-source='remote': Set to 'remote' to skip builds and resolve the digest of images by tag from the remote registry. Set to 'local' to build images locally and use digests from built images. Set to 'tag' to use tags directly from the build. Set to 'none' to use tags directly from the Kubernetes manifests.
--enable-rpc=false: Enable gRPC for exposing Skaffold events
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
-l, --label=[]: Add custom labels to deployed objects. Set multiple times for multiple labels
--loud=false: Show the build logs and output
Expand All @@ -918,6 +913,7 @@ Env vars:
* `SKAFFOLD_CACHE_ARTIFACTS` (same as `--cache-artifacts`)
* `SKAFFOLD_DEFAULT_REPO` (same as `--default-repo`)
* `SKAFFOLD_DIGEST_SOURCE` (same as `--digest-source`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_LABEL` (same as `--label`)
* `SKAFFOLD_LOUD` (same as `--loud`)
Expand Down Expand Up @@ -956,7 +952,6 @@ Options:
--detect-minikube=true: Use heuristics to detect a minikube cluster
--digest-source='remote': Set to 'remote' to skip builds and resolve the digest of images by tag from the remote registry. Set to 'local' to build images locally and use digests from built images. Set to 'tag' to use tags directly from the build. Set to 'none' to use tags directly from the Kubernetes manifests.
--enable-rpc=false: Enable gRPC for exposing Skaffold events
--event-log-file='': Save Skaffold events to the provided file after skaffold has finished executing, requires --enable-rpc=true
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
--force=false: Recreate Kubernetes resources if necessary for deployment, warning: might cause downtime!
--insecure-registry=[]: Target registries for built images which are not secure
Expand Down Expand Up @@ -1005,7 +1000,6 @@ Env vars:
* `SKAFFOLD_DETECT_MINIKUBE` (same as `--detect-minikube`)
* `SKAFFOLD_DIGEST_SOURCE` (same as `--digest-source`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_EVENT_LOG_FILE` (same as `--event-log-file`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_FORCE` (same as `--force`)
* `SKAFFOLD_INSECURE_REGISTRY` (same as `--insecure-registry`)
Expand Down Expand Up @@ -1127,6 +1121,7 @@ Examples:
Options:
-a, --build-artifacts=: File containing build result from a previous 'skaffold build --file-output'
--enable-rpc=false: Enable gRPC for exposing Skaffold events
-f, --filename='skaffold.yaml': Path or URL to the Skaffold config file
-m, --module=[]: Filter Skaffold configs to only the provided named modules
--remote-cache-dir='': Specify the location of the git repositories cache (default $HOME/.skaffold/repos)
Expand All @@ -1141,6 +1136,7 @@ Use "skaffold options" for a list of global command-line options (applies to all
Env vars:

* `SKAFFOLD_BUILD_ARTIFACTS` (same as `--build-artifacts`)
* `SKAFFOLD_ENABLE_RPC` (same as `--enable-rpc`)
* `SKAFFOLD_FILENAME` (same as `--filename`)
* `SKAFFOLD_MODULE` (same as `--module`)
* `SKAFFOLD_REMOTE_CACHE_DIR` (same as `--remote-cache-dir`)
Expand Down

0 comments on commit ffb7d2b

Please sign in to comment.