ks show

Show expanded manifests for a specific environment.

Synopsis

Show expanded manifests (resource definitions) for a specific environment.
Jsonnet manifests, each defining a ksonnet component, are expanded into their
JSON or YAML equivalents (YAML is the default). Any parameters in these Jsonnet
manifests are resolved based on environment-specific values.

When NO component is specified (no -c flag), this command expands all of
the files in the components/ directory into a list of resource definitions.
This is the YAML version of what gets deployed to your cluster with
ks apply <env-name>.

When a component IS specified via the -c flag, this command only expands the
manifest for that particular component.

  • ks validate — Check generated component manifests against the server’s API
  • ks apply — Apply local Kubernetes manifests (components) to remote clusters

Syntax

  1. ks show <env> [-c <component-filename>] [flags]

Examples

  1. # Show all of the components for the 'dev' environment, in YAML
  2. # (In other words, expands all manifests in the components/ directory)
  3. ks show dev
  4. # Show a single component from the 'prod' environment, in JSON
  5. ks show prod -c redis -o json
  6. # Show multiple components from the 'dev' environment, in YAML
  7. ks show dev -c redis -c nginx-server

Options

  1. -c, --component strings Name of a specific component (multiple -c flags accepted, allows YAML, JSON, and Jsonnet)
  2. -V, --ext-str strings Values of external variables
  3. --ext-str-file strings Read external variable from a file
  4. -o, --format string Output format. Supported values are: json, yaml (default "yaml")
  5. -h, --help help for show
  6. -J, --jpath strings Additional jsonnet library search path
  7. -A, --tla-str strings Values of top level arguments
  8. --tla-str-file strings Read top level argument from a file

Options inherited from parent commands

  1. --dir string Ksonnet application root to use; Defaults to CWD
  2. --tls-skip-verify Skip verification of TLS server certificates
  3. -v, --verbose count Increase verbosity. May be given multiple times.

SEE ALSO

  • ks - Configure your application to deploy to a Kubernetes cluster