railway variable
Manage environment variables for a service.
Usage
Aliases
railway variablesrailway varsrailway var
Subcommands
| Subcommand | Aliases | Description |
|---|---|---|
list | ls | List variables for a service |
set | Set a variable | |
delete | rm, remove | Delete a variable |
Examples
List variables
List in key-value format
Output:
Set a variable
Set multiple variables
Set variable from stdin
Delete a variable
Options for
| Flag | Description |
|---|---|
-s, --service <SERVICE> | Service to list variables for |
-e, --environment <ENV> | Environment to list variables from |
-k, --kv | Show variables in KEY=VALUE format |
--json | Output in JSON format |
Options for
| Flag | Description |
|---|---|
-s, --service <SERVICE> | Service to set the variable for |
-e, --environment <ENV> | Environment to set the variable in |
--stdin | Read value from stdin (use with single KEY) |
--skip-deploys | Skip triggering deploys |
--json | Output in JSON format |
Options for
| Flag | Description |
|---|---|
-s, --service <SERVICE> | Service to delete the variable from |
-e, --environment <ENV> | Environment to delete the variable from |
--json | Output in JSON format |
Legacy flags
The following flags are deprecated but still supported: