Knowledge base › Configuration

Environment variables

Add, edit and import variables, keep secrets hidden, and decrypt encrypted files.

Open a service's Settings → Environment vars. Changes are kept as a draft until you click Save; saving restarts the service with the new values. If you leave the tab with unsaved changes, wdot asks whether to save or discard them.

Secrets

Tick secret on a variable to hide its value in the list and in logs. Use it for passwords, tokens and keys.

Importing variables

Two buttons import many variables at once:

  • Import file — a file from your computer.
  • Import from repository — any file on the service's branch.

Both are also on the Configuration step when you add a service. Both read .env files (KEY=VALUE), YAML and JSON (top-level values), and Java .properties. After reading the file you choose which variables to add, and whether each is saved as a secret. Variables that would replace a current value are marked.

Encrypted files

If the file is encrypted, choose its method and paste the key:

MethodKey to paste
dotenvxThe DOTENV_PRIVATE_KEY for that file, from .env.keys (for .env.production it is DOTENV_PRIVATE_KEY_PRODUCTION)
SOPS (age)The age secret key, starting with AGE-SECRET-KEY-1
dotenv-vaultThe DOTENV_KEY of the environment to import

The key is used for that one import only. It is never saved, and it is cleared from the page once the file is read.

Database credentials

Copy credentials from DB adds DB_HOST, DB_PORT, DB_NAME, DB_USER and DB_PASSWORD (as a secret) from any of your databases.