How do you reload environment file in a docker swarm service?

Viewed 1940

I need to change an environment variable in my deployment (nothing else has changed). When I update my environment variables (just using export) and use docker stack deploy, the container environment is not updated. How do I make sure environment variables are updated in the container?

1 Answers

Apparently using docker stack deploy should work to update the environment. My error was not having the environment variable defined in the docker-compose.yml file.

Related