Last active
June 24, 2018 10:17
-
-
Save emj365/732ffb99b171ed181930a240c49ad524 to your computer and use it in GitHub Desktop.
example startup traefik on swarm
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker-machine ssh do-swarm0 "docker service create \ | |
--name traefik \ | |
--constraint=node.role==manager \ | |
--publish 80:80 \ | |
--publish 443:443 \ | |
--publish 8080:8080 \ | |
--publish 19000:19000 \ | |
--publish 19001:19001 \ | |
--mount type=bind,source=/var/run/docker.sock,target=/var/run/docker.sock \ | |
--network traefik-net \ | |
traefik \ | |
--entryPoints='Name:http Address::80' \ | |
--entryPoints='Name:https Address::443' \ | |
--entryPoints='Name:expo Address::19000' \ | |
--entryPoints='Name:expo-assets Address::19001' \ | |
--docker \ | |
--docker.swarmMode \ | |
--docker.domain=traefik \ | |
--docker.watch \ | |
--api" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment