Files
agence66-traefik-docker/docker-compose.yml
BeauTroll 42eb0058a1 Add file provider to Traefik for host-based services
Enable dual provider support (Docker + File) to allow routing both containerized services and services running on the host machine. Add dynamic.yml with routes for nginx-based websites (agence66.fr, walter-coiffure.fr) pointing to host gateway IP.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-22 08:34:38 +01:00

29 lines
991 B
YAML

services:
traefik:
image: traefik:latest
container_name: traefik
restart: unless-stopped
security_opt:
- no-new-privileges:true
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./traefik.yml:/etc/traefik/traefik.yml:ro
- ./dynamic.yml:/etc/traefik/dynamic.yml:ro
- ./acme.json:/acme.json
networks:
- traefik-net
labels:
- "traefik.enable=true"
- "traefik.http.routers.traefik-dashboard.rule=Host(`${DASHBOARD_HOST}`)"
- "traefik.http.routers.traefik-dashboard.entrypoints=websecure"
- "traefik.http.routers.traefik-dashboard.service=api@internal"
- "traefik.http.routers.traefik-dashboard.tls.certresolver=letsencrypt"
- "traefik.http.routers.traefik-dashboard.middlewares=traefik-auth"
- "traefik.http.middlewares.traefik-auth.basicauth.users=${DASHBOARD_USER}:${DASHBOARD_PASSWORD}"
networks:
traefik-net:
external: true