Skip to content

cmd config

github-actions[bot] edited this page Aug 25, 2026 · 3 revisions

nself config

View and manage project configuration.

Synopsis

nself config <subcommand> [flags]

Description

nself config provides a complete interface for reading and writing ɳSelf configuration values. Config is stored in .env files, nself config reads and writes them safely, preserving comments and formatting.

Secret keys (any key containing SECRET, PASSWORD, KEY, or TOKEN) are masked as *** in output by default. Pass --reveal to show plaintext values. Use --env to target a specific environment file (e.g., --env staging reads .env.staging).

The validate subcommand runs all registered configuration validators and reports pass/fail per rule. It is automatically run during nself build, but you can run it independently to check config without rebuilding.

Flags

Flag Default Description
--env "" Target environment (reads .env.{env})
--json false JSON output
--reveal false Show secret values in plaintext
--help, -h Show help

Subcommands

Name Description
export Export current config to a file or stdout
features Manage CLI-built-in feature flags
get Get a single configuration value
import Import config from a file into .env
list List all known config keys with current values
set Update a configuration value (writes to .env)
show Show all config key=value pairs (masked by default)
validate Validate configuration against all registered rules

Examples

# Show all config (secrets masked)
nself config show

# Show config with secrets revealed
nself config show --reveal

# Show config for staging environment
nself config show --env staging

# Get a single value
nself config get BASE_DOMAIN

# Get a secret value
nself config get POSTGRES_PASSWORD --reveal

# Set a value
nself config set BASE_DOMAIN myapp.dev
nself config set REDIS_ENABLED true

# List all known keys with current values and source
nself config list
nself config list --env staging

# Validate configuration
nself config validate
nself config validate --env prod

# Export config to a file
nself config export backup.env
nself config export /tmp/prod-config.env --env prod

# Import config from a file
nself config import backup.env
nself config import staging.env --env staging --force

See Also

Commands | Home

Home


Getting Started


Commands


Features


Configuration


Plugins (87 + 10 monitoring)

Free (25)
Pro (62)
Planned (26)
  • plugin-audit
  • plugin-blog
  • plugin-checkout
  • plugin-commerce
  • plugin-drm
  • plugin-export
  • plugin-flow
  • plugin-import
  • plugin-ldap
  • plugin-mailgun
  • plugin-media
  • plugin-oauth-providers
  • plugin-pages
  • plugin-postmark
  • plugin-rate-limit
  • plugin-reports
  • plugin-saml
  • plugin-scheduler
  • plugin-sendgrid
  • plugin-sso
  • plugin-subscription
  • plugin-thumb
  • plugin-transcoder
  • plugin-twilio
  • plugin-waf
  • plugin-watermark

Guides


Architecture


Reference


Licensing


Security


Brand


Operations


Contributing


Admin


Changelog


All commands (52)

Clone this wiki locally