Secrets
Secrets store sensitive values like API keys, database passwords, and encryption keys. They are encrypted at rest and injected into your application as environment variables at runtime.
Setting a secret
Section titled “Setting a secret”ske secret set STRIPE_KEYValue:Secret STRIPE_KEY set.APP_KEY is created for you when the environment is created, so you don’t need to set it.
The value is prompted with hidden input. To set it non-interactively (useful in scripts), use --value or pipe from stdin:
# Using --value flagske secret set MAIL_PASSWORD --value "your-password"
# Piping from stdinprintf '%s' "$SECRET_VALUE" | ske secret set STRIPE_KEYListing secrets
Section titled “Listing secrets”ske secret listKEY LAST MODIFIEDAPP_KEY 2026-09-15 14:30MAIL_PASSWORD 2026-09-15 14:32STRIPE_KEY 2026-09-18 09:15Secret values are never displayed — only the key name and last modification time.
Deleting a secret
Section titled “Deleting a secret”ske secret delete STRIPE_KEYDelete secret STRIPE_KEY? [y/N] ySecret STRIPE_KEY deleted.Use --force to skip the confirmation prompt:
ske secret delete STRIPE_KEY --forceImporting from a .env file
Section titled “Importing from a .env file”ske secret import .env.productionKEY ACTION LINE NOTEMAIL_PASSWORD change 3SENTRY_DSN add 5STRIPE_KEY unchanged 7
1 to add, 1 to change, 1 unchanged, 0 to remove, 0 skipped.Apply 2 changes to production? [y/N] ySecrets imported: 1 added, 1 changed, 0 removed.ske secret import prints what changes first, never showing values, then asks before applying. --dry-run only prints the changes, --yes applies without asking, and --prune also removes secrets the file doesn’t set. - reads the file from standard input. A file with lines that can’t be read changes nothing.
A key that overrides a value SKE injects, such as DB_HOST, is marked overrides the platform's value.
Per-environment secrets
Section titled “Per-environment secrets”Secrets are scoped to an environment. Each environment has its own set of secrets. To manage secrets for a specific environment:
ske secret set MAIL_PASSWORD --env productionske secret set MAIL_PASSWORD --env stagingske secret list --env productionStorage
Section titled “Storage”Secrets are stored in your cloud provider’s secret management service:
| Provider | Storage |
|---|---|
| AWS | SSM Parameter Store (SecureString) |
| GCP | Secret Manager |
SKE manages the lifecycle — creating, updating, and deleting secrets in your cloud account. The values are encrypted using your cloud provider’s default encryption keys and are only decrypted at runtime when your application starts.
When secrets take effect
Section titled “When secrets take effect”Secrets are injected as environment variables when your application container starts. Changing a secret does not immediately affect running instances. The new value takes effect on the next deployment or redeployment.
To apply changed secrets without deploying new code, trigger an environment sync:
ske deploy --env production