How to manage settings
View current configuration
To view all available settings and their active values from the command line, run:
These settings are type-validated and you may verify your setup at any time with:
Configure settings for the active profile
To update a setting for the active profile, run:
For example, to set the PREFECT_API_URL
setting to http://127.0.0.1:4200/api
, run:
To restore the default value for a setting, run:
For example, to restore the default value for the PREFECT_API_URL
setting, run:
Create a new profile
To create a new profile, run:
To switch to a new profile, run:
Configure settings for a project
To configure settings for a project, create a prefect.toml
or .env
file in the project directory and add the settings with the values you want to use.
For example, to configure the PREFECT_API_URL
setting to http://127.0.0.1:4200/api
, create a .env
file with the following content:
To configure the PREFECT_API_URL
setting to http://127.0.0.1:4200/api
in a prefect.toml
file, create a prefect.toml
file with the following content:
Refer to the setting concept guide for more information on how to configure settings and the settings reference guide for more information on the available settings.
Configure temporary settings for a process
To configure temporary settings for a process, set an environment variable with the name matching the setting you want to configure.
For example, to configure the PREFECT_API_URL
setting to http://127.0.0.1:4200/api
for a process, set the PREFECT_API_URL
environment variable to http://127.0.0.1:4200/api
.
You can use this to run a command with the temporary setting: