All pages

Build and deploy

Variables

Available

Variables are the settings and secrets a service is given when it runs.

A database address, an API key, a feature switch: anything that differs between environments or must not be in the code.

Where a variable is set

A variable is set for the whole workspace, for a project, for an environment, or for one service. A service gets all four, and the narrower one wins: a service's own value replaces the environment's, which replaces the project's, which replaces the workspace's.

Secrets

A variable marked as a secret is sealed with the installation's RUNONE_SECRET_KEY before it is stored. Its value is never shown again, in the dashboard or through the API; you can only replace it. Secrets stay out of Git and out of logs, and reach a build only when the service names them.

Importing a .env file

Import .env on the Variables page reads a pasted .env file into one scope. It first shows what it would do, key by key: new, replaces, unchanged. Names that look like credentials (KEY, SECRET, TOKEN, PASSWORD and the like) are proposed as secrets; you decide. Nothing is saved until you apply.

When a change takes effect

Changing a variable does not touch what is running. The next deployment fixes the service's variables as a numbered configuration; the service's Configuration tab lists them with what changed. Rolling back brings back the configuration that deployment had.

A value that a build bakes in, such as a NEXT_PUBLIC_* variable, needs a new build: choose Deploy, not Restart.