Skip to content

Instantly share code, notes, and snippets.

@mattmcla
Created September 5, 2017 16:37
Show Gist options
  • Save mattmcla/9215ae261d911ff3699e339d0a63e508 to your computer and use it in GitHub Desktop.
Save mattmcla/9215ae261d911ff3699e339d0a63e508 to your computer and use it in GitHub Desktop.
version: '2'
services:
consul:
image: consul
command: consul agent -server -dev -client=0.0.0.0 -ui -bootstrap -log-level warn
ports:
- "8400:8400"
- "8500:8500"
- "8600:53/udp"
reverse-proxy:
image: reverse-proxy
command: traefik --consulcatalog.endpoint=consul:8500
ports:
- "8080:8080"
- "8081:80"
depends_on:
- consul
links:
- consul
web-server:
image: crccheck/hello-world
ports:
- "8000:8000"
environment:
- SERVICE_TAGS=traefik.enable=true,traefik.frontend.entryPoints=http,traefik.frontend.rule=Host:localhost
registrator:
depends_on:
- consul
image: gliderlabs/registrator:master
command: -internal consul://consul:8500
volumes:
- /var/run/docker.sock:/tmp/docker.sock
links:
- consul
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment