docker service update --env-add NODE_ENV=staging web
Add an environment variable to a service
Injects NODE_ENV=staging into the service's tasks and rolls them over. --env-rm removes variables by name. Combined with --image, one command can redeploy with new config.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.