Hello, i want to overwrite this configuration by u...
# prefect-community
g
Hello, i want to overwrite this configuration by using environment variables.So which one is correct? Thanks!
Copy code
export PREFECT__SERVICES__SERVICES__TOWEL__MAX__SCHEDULED__RUNS__PER__FLOW=1
or
export PREFECT__MAX__SCHEDULED__RUNS__PER__FLOW=1
a
I'd say: PREFECT__SERVICES__TOWEL__MAX_SCHEDULED_RUNS_PER_FLOW
g
i set ~/.prefect/config.toml like this
Copy code
[server]
    [server.ui]
    port = "8081"
    host_port = "8081"

[services]

    host = "0.0.0.0"

    [services.towel]
    max_scheduled_runs_per_flow = 1
ui port change is ok, but max_scheduled_runs_per_flow doesn’t work, still has 10 upcoming runs
k
What is your Prefect version?
g
1.2.2
k
Did you re-deploy server? You need to de-redeploy for these changes to take effect
g
yes, re-deploy server already, but still doesn't work
k
Did you deploy with helm or
prefect server start
?
g
use prefect server start
k
Prefect server start should definitely use that and it seems like the right place. Do you potentially have an env var set also?
Or another config.toml?
v
Same for me, changes in the [services] section don't seem to be picked up by server (using 1.3).
Lookin at the code it seems that these values are not passed to server when running
prefect server start
, so the values hard coded in https://github.com/PrefectHQ/server/blob/5d2c538dac3c246fcafc1ec2556f46bdf987f0fc/src/prefect_server/config.toml#L85 are used.
I tried to launch server and then change the value in the towel container (
docker exec -it
intothe container then modify the config.toml file using python), but that does not work either, since the config is loaded only once during start-up.