docker service update --publish-add 8080:80 web

Category: Docker

docker service update --publish-add 8080:80 web

Add a published port to a service

Exposes container port 80 on host port 8080 without recreating the service definition. The counterpart --publish-rm removes it. Port changes roll through the service's tasks.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.