Yao Zhao
Yao Zhao

Reputation: 4613

How to add existing swarm service to a network?

I know, when creating a servcie, we could specify the network. But if have already had some services, then how to add them to a network?

Upvotes: 1

Views: 1328

Answers (1)

omu_negru
omu_negru

Reputation: 4770

try to update the service, like so:

docker service update --network-add my_network my_service_name

You can read here about what else you can do with the update command

Upvotes: 3

Related Questions