The controller and router deployments for Linux and Docker utilize Ziti's built-in one-shot config generator and will not re-generate their config.yml unless you set ZITI_BOOTSTRAP_CONFIG=force
. By default, these prod-oriented deployments preserve any existing config.yml because there's no way to ensure it was not modified after it was initially generated, and forcing config generation will clobber any modifications you made since it was generated.
You're using the router container. To directly edit the one-shot generated config.yml:
docker compose exec ziti-router vi /ziti-router/config.yml
or, depending on your term emulator settings, this may work better:
docker compose run --rm --entrypoint= ziti-router vi /ziti-router/config.yml
If you experience terminal corruption issues with both of those approaches, you can always copy the config.yml to the host for editing before replacing it.
docker compose cp ziti-router:/ziti-router/config.yml .
then:
docker compose cp ./config.yml ziti-router:/ziti-router/
docker compose up ziti-router --force-recreate
The purpose of the final up
command is to correct the file owner based on the value of ZIGGY_UID
in the compose project's environment and restart the router to load the new config.
If you frequently edit the config.yml, you may wish to change the way the router state is persisted from a Docker named volume to a Docker host bind directory by editing the example compose.yml file. That way, you can edit the config.yml directly on the host and restart the router container to load the new config.