Last active
March 15, 2016 08:21
-
-
Save nstapelbroek/d624d755d844c383f5ac to your computer and use it in GitHub Desktop.
Commands used in the Service Discovery blogpost @ https://enrise.com/2016/03/an-introduction-to-service-discovery/
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
| curl -H "Content-type: application/json" 'http://10.200.2.1:8500/v1/catalog/services' | |
| # Or, to get an overview of our specific hello-world service | |
| curl -H "Content-type: application/json" 'http://10.200.2.1:8500/v1/catalog/service/hello-world' |
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
| for i in $(seq 5); do docker run -h sdblog_app$i --name sdblog_app$i -P -d tutum/hello-world; done |
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 run -d --name=sdblog_consul --net=host gliderlabs/consul-server -bootstrap -advertise=10.200.2.1 |
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 run -it --name sdblog_nginx -e "CONSUL=10.200.2.1:8500" -e "SERVICE=hello-world" -p 80:80 nstapelbroek/blog-sd-nginx |
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 run --name {appname} -h {appname} -P -d tutum/hello-world |
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 run -d --name=sdblog_registrator --net=host --volume=/var/run/docker.sock:/tmp/docker.sock gliderlabs/registrator:latest consul://10.200.2.1:8500 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment