traefik/docs/content/user-guides/docker-compose/basic-example/docker-compose.yml
2019-08-06 08:46:04 -07:00

26 lines
649 B
YAML

version: "3.3"
services:
traefik:
image: "traefik:v2.0.0-beta1"
container_name: "traefik"
command:
#- "--log.level=DEBUG"
- "--api=true"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
ports:
- "80:80"
- "8080:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
whoami:
image: "containous/whoami"
container_name: "simple-service"
labels:
- "traefik.enable=true"
- "traefik.http.routers.whoami.rule=Host(`whoami.localhost`)"
- "traefik.http.routers.whoami.entrypoints=web"