Skip to main content

set config

The kots set config allows setting values for application config items in the latest release version.

Introduced in KOTS v1.31.0

Usage

kubectl kots set config [appSlug] [KEY_1=VAL_1 ... KEY_N=VAL_N] [flags]
  • Provide [flags] according to the table below
FlagTypeDescription
--config-filestringpath to a manifest containing config values (must be apiVersion: kots.io/v1beta1, kind: ConfigValues)
--mergewhen set to true, only keys specified in config file will be updated. This flag can only be used when --config-file flag is used.
--keystringname of a single key to set. This flag requires --value or --value-from-file flags
--value stringthe value to set for the key specified in the --key flag. This flag cannot be used with --value-from-file flag.
--value-from-filestringpath to the file containing the value to set for the key specified in the --key flag. This flag cannot be used with --value flag.
--deploywhen set, automatically deploy the latest version with the new configuration
--skip-preflightsset to true to skip preflight checks when deploying new version
-n, --namespacestringthe namespace where the admin console is running (required)

About Strict Preflight Checks

If any strict preflight checks are configured, the --skip-preflights flag is not honored because preflight checks must run and contain no failures before the application is deployed.

When the --deploy option is provided and there are strict preflight checks, the preflight checks always run. The deployment waits for up to 15 minutes for the preflight checks to complete. If the checks complete without strict preflight failures, the release deploys. If the checks do not complete within 15 minutes, the release does not deploy. If there are one or more strict preflight failures, the release does not deploy.

For more information about strict preflight checks, see About Preflight Checks and Support Bundles.

Examples

kubectl kots set config myapp -n default --config-file /path/to/local/config.yaml
kubectl kots set config myapp -n default --key config-item-name --value-from-file /path/to/config/file/value.txt
kubectl kots set config myapp -n default config-item-name="config item value"
kubectl kots set config myapp -n default --key config-item-name --value "config item value"