Give each environment its own variables, the settings it hands to your app such as LOG_LEVEL, so Production can differ from Preview.
Before you start
You need a project. See Create a project.
Add a variable
- In your project, open Runtime > Environments.
- Click Production.
- Under Environment variables, click Add variable.
- Enter a Key, such as
LOG_LEVEL. - Enter a Value, such as
debug. - Click Add variables. You should now see "Variable added" and
LOG_LEVELunder Environment variables, with its value hidden as••••••••.
To add several at once, open Paste in the dialog and paste KEY=value lines instead.
To change a value, add the same Key again with the new Value. Studio says "Variable saved".
Delete a variable
- Open the ⋯ menu on the variable's row.
- Click Delete. Anything that reads it fails until you add it again.
- Click Delete variable. You should now see "No variables yet." under Environment variables.