homeserver/proxy/docker-compose.yaml

47 lines
1.1 KiB
YAML
Raw Normal View History

2021-01-09 20:40:51 +01:00
version: "3.3"
services:
traefik:
image: traefik:v2.3
2021-01-09 20:40:51 +01:00
restart: always
command:
- "--api.insecure=true"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
ports:
- "80:80"
- "443:443"
networks:
- web
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
labels:
- "traefik.enable=true"
- "traefik.http.routers.traefik.rule=Host(`traefik.${DOMAIN}`)"
- "traefik.http.routers.traefik.entrypoints=web"
- "traefik.http.services.traefik.loadbalancer.server.port=8080"
- "docker.group=proxy"
2021-01-09 20:40:51 +01:00
extra_hosts:
- host.docker.internal:172.17.0.1
whoami:
image: containous/whoami
networks:
- web
labels:
- "traefik.enable=true"
- "traefik.http.routers.whoami.rule=Host(`whoami.${DOMAIN}`)"
- "traefik.http.routers.whoami.entrypoints=web"
- "traefik.http.services.whoami.loadbalancer.server.port=80"
- "docker.group=proxy"
2021-01-09 20:40:51 +01:00
restart: unless-stopped
networks:
web:
external: true