Use $STACK_NAME for default router name..

..instead of hard-coded `traefik`
This commit is contained in:
3wc 2022-10-18 17:06:11 -04:00
parent fcff3a2d6a
commit 975d8e01a4
2 changed files with 9 additions and 9 deletions

View File

@ -10,5 +10,5 @@ services:
labels: labels:
- "traefik.enable=true" - "traefik.enable=true"
- "traefik.http.services.traefik.loadbalancer.server.port=web" - "traefik.http.services.traefik.loadbalancer.server.port=web"
- "traefik.http.routers.traefik.entrypoints=web-secure" - "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
- "traefik.http.routers.traefik.service=api@internal" - "traefik.http.routers.${STACK_NAME}.service=api@internal"

View File

@ -40,13 +40,13 @@ services:
order: start-first order: start-first
labels: labels:
- "traefik.enable=true" - "traefik.enable=true"
- "traefik.http.services.traefik.loadbalancer.server.port=web" - "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=web"
- "traefik.http.routers.traefik.rule=Host(`${DOMAIN}`)" - "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`)"
- "traefik.http.routers.traefik.entrypoints=web-secure" - "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
- "traefik.http.routers.traefik.tls.certresolver=${LETS_ENCRYPT_ENV}" - "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
- "traefik.http.routers.traefik.tls.options=default@file" - "traefik.http.routers.${STACK_NAME}.tls.options=default@file"
- "traefik.http.routers.traefik.service=api@internal" - "traefik.http.routers.${STACK_NAME}.service=api@internal"
- "traefik.http.routers.traefik.middlewares=security@file" - "traefik.http.routers.${STACK_NAME}.middlewares=security@file"
- "coop-cloud.${STACK_NAME}.version=1.1.1+v2.8.1" - "coop-cloud.${STACK_NAME}.version=1.1.1+v2.8.1"
networks: networks: