Skip to content

Instantly share code, notes, and snippets.

@clintkitson
Last active March 10, 2016 18:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save clintkitson/9459ef212651e2334312 to your computer and use it in GitHub Desktop.
Save clintkitson/9459ef212651e2334312 to your computer and use it in GitHub Desktop.
docker swarm
eval $(docker-machine env manager)
TOKEN=$(docker run --rm swarm create)
docker-machine create --driver=virtualbox --swarm --swarm-master --swarm-discovery token://$TOKEN manager
docker-machine create --driver=virtualbox --swarm --swarm-discovery token://$TOKEN agent1
docker-machine create --driver=virtualbox --swarm --swarm-discovery token://$TOKEN agent2
eval $(docker-machine env --swarm manager)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment