-
Notifications
You must be signed in to change notification settings - Fork 0
Swarm Setup
Ryan Sandor Richards edited this page Jan 14, 2016
·
10 revisions
Herein lies the incantations, most arcane, that are required to setup and use swarm on your local computing machina.
- collect docker-toolbox
- clone devops-scripts github repository
- copy
devops-scripts/ansible/roles/docker_client/ca.pemintodevops-scripts/ansible/roles/docker_client/files/certs/swarm-manager - combine the following with your
~/.bash_profile
export DOCKER_HOST=tcp://localhost:2375
export DOCKER_CERT_PATH=<path_to_devops_scripts>/ansible/roles/docker_client/files/certs/swarm-manager
export DOCKER_TLS_VERIFY=1
# used to create blocking tunnel to swarm host
# usage: setupSwarm <services_host>
alias setupSwarm='ssh -NL 2375:localhost:2375'
# sugar functions
alias setupSwarmGamma='setupSwarm gamma-services'
alias setupSwarmDelta='setupSwarm delta-services'
- run either
setupSwarmGammaorsetupSwarmDeltain one shell
- note: you will need to dedicate one shell to run this command, it is a blocking call. To stop the tunnel simply press
control + cin this shell
- In any other shell you are now able to run any
dockercommands. ex.
-
docker pslist all running containers across the entire environment -
docker infolist all docks with nice info