Skip to content
SHC Docs

shc vault export

export secrets to an encrypted bundle

Export secrets to a password-encrypted bundle. When —password is omitted the command prompts for one (with confirmation). Narrow the export with the —tenant/—stack/—environment/—deployment/—app filters; —bundle-format picks the payload encoding (yaml or json). Use ”-” as the output file to write the encrypted bundle to stdout.

shc vault export <output-file> [flags]
shc vault export secrets.enc
shc vault export myblog.enc -s myblog -e default
shc vault export - --app postgres -P s3cret > postgres-secrets.enc
--app string app-name filter
--bundle-format string bundle payload encoding: yaml|json (default "yaml")
--deployment string deployment filter
-e, --environment string environment filter
-h, --help help for export
-P, --password string export password (prompts when empty)
-s, --stack string stack filter
--tenant string tenant filter
--config stringArray extra YAML config file to layer on top of auto-discovered config; repeatable, later files win
-d, --debug enable debug mode (default: $SHC_DEBUG)
--exclude string comma-separated dotted paths to drop
--fields string comma-separated columns/keys to show (and their order)
--filter string comma-separated dotted paths to keep (drops everything else)
-o, --output string output format: tty|text|json|yaml (default: $SHC_OUTPUT)
-v, --verbose verbose output (default: $SHC_VERBOSE)