From 15e0cf3bb98e5337164cea6b729bd9f28513c916 Mon Sep 17 00:00:00 2001 From: Philip Cheung Date: Tue, 8 Oct 2024 14:11:14 +0800 Subject: [PATCH] update docker file --- docker-compose.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 4b38556..eb6f87a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,7 +3,7 @@ services: build: context: . dockerfile: Dockerfile - container_name: docker-next + container_name: allAndOne env_file: - .env.local @@ -17,19 +17,19 @@ services: - traefik.docker.network=traefik-public - traefik.constraint-label=traefik-public - - traefik.http.services.${STACK_NAME?Variable not set}-frontend.loadbalancer.server.port=80 + - traefik.http-frontend.loadbalancer.server.port=80 - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`) - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.entrypoints=http + - traefik.http.routers.frontend-http.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`) + - traefik.http.routers.frontend-http.entrypoints=http - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`) - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.entrypoints=https - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls=true - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls.certresolver=le + - traefik.http.routers.frontend-https.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`) + - traefik.http.routers.frontend-https.entrypoints=https + - traefik.http.routers.frontend-https.tls=true + - traefik.http.routers.frontend-https.tls.certresolver=le # Enable www redirection for HTTP and HTTPS - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.middlewares=${STACK_NAME?Variable not set}-www-redirect - - traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.middlewares=https-redirect,${STACK_NAME?Variable not set}-www-redirect + - traefik.http.routers.frontend-https.middlewares=www-redirect + - traefik.http.routers.frontend-http.middlewares=https-redirect,www-redirect networks: - traefik-public - default \ No newline at end of file