refactor: move traefik configuration to docker-compose files via labels

This commit is contained in:
2025-12-05 04:03:24 +01:00
parent d776124f26
commit fc6a11397b
17 changed files with 356 additions and 74 deletions
+22 -4
View File
@@ -10,13 +10,31 @@ services:
- /var/run/docker.sock:/var/run/docker.sock:ro
env_file: .env
labels:
- "traefik.enable=true"
- "traefik.docker.network=traefik-proxy"
- "traefik.enable=true"
- "traefik.docker.network=traefik-proxy"
# Prod Router
- "traefik.http.routers.glance.rule=Host(`glance.forust.xyz`)"
- "traefik.http.routers.glance.entrypoints=websecure"
- "traefik.http.routers.glance.middlewares=security-headers"
- "traefik.http.routers.glance.tls=true"
# Local Router
- "traefik.http.routers.glance-local.rule=Host(`glance.workstation.local`) || Host(`glance.local`)"
- "traefik.http.routers.glance-local.entrypoints=websecure"
- "traefik.http.routers.glance-local.middlewares=security-headers"
- "traefik.http.routers.glance-local.tls=true"
# Dev Router
- "traefik.http.routers.glance-dev.rule=Host(`glance.gigaforust.local`)"
- "traefik.http.routers.glance-dev.entrypoints=websecure"
- "traefik.http.routers.glance-dev.middlewares=security-headers"
- "traefik.http.routers.glance-dev.tls=true"
networks:
- traefik-proxy
- traefik-proxy
dns:
- 1.1.1.1
- 8.8.8.8
networks:
traefik-proxy:
external: true
external: true