From 02fea121cf2d621c9f723e196e33c8273f579e98 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:19:34 +0100 Subject: [PATCH 01/28] Testing whether folder works --- dev.env | 4 ++-- docker-compose.yaml | 4 ++++ prod.env | 2 +- prod/route-to-staging-dev.yaml | 0 4 files changed, 7 insertions(+), 3 deletions(-) create mode 100644 prod/route-to-staging-dev.yaml diff --git a/dev.env b/dev.env index 6b520c4..e878701 100644 --- a/dev.env +++ b/dev.env @@ -1,9 +1,9 @@ PORT=898 HTTPS_PORT=446 -ENV=dev +ENV=prod NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-staging-v02.api.letsencrypt.org/directory DOMAIN=dev.kovagoadi.hu ACME_BYPASS=false TRAEFIK_LEGACY_OPT= -# TRAEFIK_LEGACY_OPT="--providers.file.filename=/etc/traefik/forward-to-legacy-nginx.yaml" \ No newline at end of file +TRAEFIK_LEGACY_OPT="--providers.file.directory=/etc/traefik" \ No newline at end of file diff --git a/docker-compose.yaml b/docker-compose.yaml index d0ab6a3..05b9487 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -6,6 +6,7 @@ services: - no-new-privileges:true networks: - proxy + - legacy-nginx command: - "--providers.docker=true" - "--providers.docker.exposedbydefault=false" @@ -48,5 +49,8 @@ services: - traefik.http.routers.https.tls.certresolver=letsencrypt networks: proxy: + legacy-nginx: + name: proxy + external: true volumes: letsencrypt: \ No newline at end of file diff --git a/prod.env b/prod.env index 9a3f01a..dc8856b 100644 --- a/prod.env +++ b/prod.env @@ -5,4 +5,4 @@ NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-v02.api.letsencrypt.org/directory DOMAIN=kovagoadi.hu ACME_BYPASS=true -TRAEFIK_LEGACY_OPT="--providers.file.filename=/etc/traefik/forward-to-legacy-nginx.yaml" \ No newline at end of file +TRAEFIK_LEGACY_OPT="--providers.file.directory=/etc/traefik" \ No newline at end of file diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml new file mode 100644 index 0000000..e69de29 -- 2.49.1 From 1de238172d053d6cd6f3b19374b05ad828c68e54 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:24:31 +0100 Subject: [PATCH 02/28] Testing --- dev.env | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev.env b/dev.env index e878701..ba68bc5 100644 --- a/dev.env +++ b/dev.env @@ -5,5 +5,5 @@ NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-staging-v02.api.letsencrypt.org/directory DOMAIN=dev.kovagoadi.hu ACME_BYPASS=false -TRAEFIK_LEGACY_OPT= +# TRAEFIK_LEGACY_OPT= TRAEFIK_LEGACY_OPT="--providers.file.directory=/etc/traefik" \ No newline at end of file -- 2.49.1 From c4676b535bc1e8184222f2f3794c06deacce76bb Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:26:02 +0100 Subject: [PATCH 03/28] Changes --- docker-compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 05b9487..1e4a940 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik: + traefik2: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From cc9e9857b18ac49d6662381b16100f0d68375f9f Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:29:28 +0100 Subject: [PATCH 04/28] Changed to dev --- dev.env | 2 +- docker-compose.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dev.env b/dev.env index ba68bc5..7c085dd 100644 --- a/dev.env +++ b/dev.env @@ -1,6 +1,6 @@ PORT=898 HTTPS_PORT=446 -ENV=prod +ENV=dev NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-staging-v02.api.letsencrypt.org/directory DOMAIN=dev.kovagoadi.hu diff --git a/docker-compose.yaml b/docker-compose.yaml index 1e4a940..422ed39 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik2: + traefik3: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From 5fd31a685bb5fd9bb431674a13da1eb68746e927 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:42:05 +0100 Subject: [PATCH 05/28] Added staging configuration --- prod/route-to-staging-dev.yaml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index e69de29..339a3ca 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -0,0 +1,26 @@ +http: + routers: + staging: + rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + entryPoints: + - "web" + service: "dev-staging" + priority: 100 +https: + routers: + staging-secure: + rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + entryPoints: + - "https" + service: "dev-staging-secure" + priority: 100 + +services: + dev-staging: + loadBalancer: + servers: + - url: "http://192.168.1.85:8080" + dev-staging-secure: + loadBalancer: + servers: + - url: "https://192.168.1.85:445" -- 2.49.1 From 9fd45fea2725f4aceb918f1601548bc63ee824af Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:44:05 +0100 Subject: [PATCH 06/28] Changed stuff --- docker-compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 422ed39..c2fd9de 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik3: + traefik4: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From 849fbd6e66e4dd68128e4a1da30aeac947d47559 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:48:21 +0100 Subject: [PATCH 07/28] Test dashboard --- docker-compose.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docker-compose.yaml b/docker-compose.yaml index c2fd9de..c969c04 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -20,6 +20,10 @@ services: - "--certificatesresolvers.letsencrypt.acme.email=kovagoadi@gmail.com" - "--certificatesresolvers.letsencrypt.acme.storage=/letsencrypt/acme.json" - "--certificatesResolvers.letsencrypt.acme.caServer=${CERTBOT_CA_RESOLVER}" + - "traefik.http.routers.dashboard.rule=Host(`192.168.1.85:898`) && (PathPrefix(`/api`) || PathPrefix(`/dashboard`))" + - "traefik.http.routers.dashboard.service=api@internal" + - "traefik.http.routers.dashboard.middlewares=auth" + - "traefik.http.middlewares.auth.basicauth.users=test:$$apr1$$H6uskkkW$$IgXLP6ewTrSuBkTrqE8wj/,test2:$$apr1$$d9hr9HBB$$4HxwgUir3HP4EsggP/QNo0" - "${TRAEFIK_LEGACY_OPT:-}" - "--providers.file.watch=true" ports: -- 2.49.1 From 80d27d349e5932d5b14ceabb342e546bf658e6e1 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 14:59:45 +0100 Subject: [PATCH 08/28] Debugging level --- docker-compose.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/docker-compose.yaml b/docker-compose.yaml index c969c04..01c4edc 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -8,6 +8,7 @@ services: - proxy - legacy-nginx command: + - "--log.level=DEBUG" - "--providers.docker=true" - "--providers.docker.exposedbydefault=false" - "--providers.docker.network=proxy" -- 2.49.1 From f5f727b4f0a89d873178b849a14f9c02ccbbd7ee Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:07:31 +0100 Subject: [PATCH 09/28] new config --- prod/route-to-staging-dev.yaml | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index 339a3ca..e0f8070 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -1,26 +1,30 @@ http: routers: + # Router for HTTP (Port 80) staging: rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" entryPoints: - "web" - service: "dev-staging" + service: "dev-staging" priority: 100 -https: - routers: + + # Router for HTTPS (Port 443) staging-secure: rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" entryPoints: - "https" service: "dev-staging-secure" priority: 100 + tls: {} # <--- This enables TLS for this router -services: - dev-staging: - loadBalancer: - servers: - - url: "http://192.168.1.85:8080" - dev-staging-secure: - loadBalancer: - servers: - - url: "https://192.168.1.85:445" + services: + dev-staging: + loadBalancer: + servers: + - url: "http://192.168.1.85:8080" + + dev-staging-secure: + loadBalancer: + servers: + # Note: Ensure Traefik trusts the cert at .85 or set insecureSkipVerify + - url: "https://192.168.1.85:445" \ No newline at end of file -- 2.49.1 From 081713540675b6b5735010e7453587383cf666e1 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:09:09 +0100 Subject: [PATCH 10/28] New name --- docker-compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 01c4edc..1589c09 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik4: + traefik5: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From 165d08fd1546de0008bedc3f666b5e391cc316d6 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:11:29 +0100 Subject: [PATCH 11/28] Higher priority --- docker-compose.yaml | 2 +- prod/route-to-staging-dev.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 1589c09..f1d1a7f 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik5: + traefik6: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index e0f8070..0bacc74 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -6,7 +6,7 @@ http: entryPoints: - "web" service: "dev-staging" - priority: 100 + priority: 1_000_000 # Router for HTTPS (Port 443) staging-secure: -- 2.49.1 From b0c827a650d56c157d99027a37c85b557af2f651 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:18:20 +0100 Subject: [PATCH 12/28] Removed dashboard --- docker-compose.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index f1d1a7f..9730c4b 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -21,10 +21,6 @@ services: - "--certificatesresolvers.letsencrypt.acme.email=kovagoadi@gmail.com" - "--certificatesresolvers.letsencrypt.acme.storage=/letsencrypt/acme.json" - "--certificatesResolvers.letsencrypt.acme.caServer=${CERTBOT_CA_RESOLVER}" - - "traefik.http.routers.dashboard.rule=Host(`192.168.1.85:898`) && (PathPrefix(`/api`) || PathPrefix(`/dashboard`))" - - "traefik.http.routers.dashboard.service=api@internal" - - "traefik.http.routers.dashboard.middlewares=auth" - - "traefik.http.middlewares.auth.basicauth.users=test:$$apr1$$H6uskkkW$$IgXLP6ewTrSuBkTrqE8wj/,test2:$$apr1$$d9hr9HBB$$4HxwgUir3HP4EsggP/QNo0" - "${TRAEFIK_LEGACY_OPT:-}" - "--providers.file.watch=true" ports: -- 2.49.1 From 50aa92497069ad617209791429c7602f90735c5d Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:23:26 +0100 Subject: [PATCH 13/28] Changed to prod --- dev.env | 2 +- docker-compose.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dev.env b/dev.env index 7c085dd..ba68bc5 100644 --- a/dev.env +++ b/dev.env @@ -1,6 +1,6 @@ PORT=898 HTTPS_PORT=446 -ENV=dev +ENV=prod NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-staging-v02.api.letsencrypt.org/directory DOMAIN=dev.kovagoadi.hu diff --git a/docker-compose.yaml b/docker-compose.yaml index 9730c4b..dadf7ba 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik6: + traefik7: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From cd77dd9fa055f9f80d180396985b5b01dca20cde Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:29:52 +0100 Subject: [PATCH 14/28] Set domain restriction1 --- prod/forward-to-legacy-nginx.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prod/forward-to-legacy-nginx.yaml b/prod/forward-to-legacy-nginx.yaml index 4da1e72..ae38952 100644 --- a/prod/forward-to-legacy-nginx.yaml +++ b/prod/forward-to-legacy-nginx.yaml @@ -4,7 +4,7 @@ tcp: routers: # Router for HTTPS (Passthrough) nginx-legacy-router-secure: - rule: "HostSNI(`*`)" + rule: "HostSNI(`tar.kovagoadi.hu`)" service: nginx-legacy-service-secure # Passthrough must be true for SSL to reach Nginx encrypted tls: -- 2.49.1 From 417e55ac8a62288b8be1805daa0afcedbb128cc0 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:36:32 +0100 Subject: [PATCH 15/28] Moved to env --- dev.env | 2 +- dev/forward-to-legacy-nginx.yaml | 47 +++++++++++++++++++++++++++++++ dev/route-to-staging-dev.yaml | 30 ++++++++++++++++++++ prod/forward-to-legacy-nginx.yaml | 2 +- 4 files changed, 79 insertions(+), 2 deletions(-) create mode 100644 dev/forward-to-legacy-nginx.yaml create mode 100644 dev/route-to-staging-dev.yaml diff --git a/dev.env b/dev.env index ba68bc5..7c085dd 100644 --- a/dev.env +++ b/dev.env @@ -1,6 +1,6 @@ PORT=898 HTTPS_PORT=446 -ENV=prod +ENV=dev NETWORK_NAME=proxy CERTBOT_CA_RESOLVER=https://acme-staging-v02.api.letsencrypt.org/directory DOMAIN=dev.kovagoadi.hu diff --git a/dev/forward-to-legacy-nginx.yaml b/dev/forward-to-legacy-nginx.yaml new file mode 100644 index 0000000..ae38952 --- /dev/null +++ b/dev/forward-to-legacy-nginx.yaml @@ -0,0 +1,47 @@ +# ./traefik/forward-to-legacy-nginx.yaml + +tcp: + routers: + # Router for HTTPS (Passthrough) + nginx-legacy-router-secure: + rule: "HostSNI(`tar.kovagoadi.hu`)" + service: nginx-legacy-service-secure + # Passthrough must be true for SSL to reach Nginx encrypted + tls: + passthrough: true + priority: 10 + entryPoints: + - "https" + + services: + # Service defining the external IP + nginx-legacy-service-secure: + loadBalancer: + servers: + # This is the actual external IP and Port of your Nginx + - address: "webserver:443" + +http: + routers: + # 1. TRAEFIK-MANAGED ACME HANDLER (Removed manual router) + traefik-acme-handler: + rule: "Host(`test-whoami.kovagoadi.hu`) && PathPrefix(`/.well-known/acme-challenge/`)" + entryPoints: + - "web" + service: "acme-http@internal" # This is the internal service name + priority: 1000 # High priority to ensure it wins + + # 2. THE HTTP CATCH-ALL (Sends other ACME and HTTP to Nginx) + nginx-legacy-router: + rule: "HostRegexp(`^.+$`)" + service: nginx-legacy-service + # Low priority ensures specific containers are handled first, but before the default acme-handler + priority: 90 + entryPoints: + - "web" + + services: + nginx-legacy-service: + loadBalancer: + servers: + - url: "http://webserver:80" \ No newline at end of file diff --git a/dev/route-to-staging-dev.yaml b/dev/route-to-staging-dev.yaml new file mode 100644 index 0000000..0bacc74 --- /dev/null +++ b/dev/route-to-staging-dev.yaml @@ -0,0 +1,30 @@ +http: + routers: + # Router for HTTP (Port 80) + staging: + rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + entryPoints: + - "web" + service: "dev-staging" + priority: 1_000_000 + + # Router for HTTPS (Port 443) + staging-secure: + rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + entryPoints: + - "https" + service: "dev-staging-secure" + priority: 100 + tls: {} # <--- This enables TLS for this router + + services: + dev-staging: + loadBalancer: + servers: + - url: "http://192.168.1.85:8080" + + dev-staging-secure: + loadBalancer: + servers: + # Note: Ensure Traefik trusts the cert at .85 or set insecureSkipVerify + - url: "https://192.168.1.85:445" \ No newline at end of file diff --git a/prod/forward-to-legacy-nginx.yaml b/prod/forward-to-legacy-nginx.yaml index ae38952..4da1e72 100644 --- a/prod/forward-to-legacy-nginx.yaml +++ b/prod/forward-to-legacy-nginx.yaml @@ -4,7 +4,7 @@ tcp: routers: # Router for HTTPS (Passthrough) nginx-legacy-router-secure: - rule: "HostSNI(`tar.kovagoadi.hu`)" + rule: "HostSNI(`*`)" service: nginx-legacy-service-secure # Passthrough must be true for SSL to reach Nginx encrypted tls: -- 2.49.1 From 1323c7dcd6d4b5644a08f27432cbe39394a4b947 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:48:26 +0100 Subject: [PATCH 16/28] Moving back to every domain --- dev/forward-to-legacy-nginx.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/forward-to-legacy-nginx.yaml b/dev/forward-to-legacy-nginx.yaml index ae38952..4da1e72 100644 --- a/dev/forward-to-legacy-nginx.yaml +++ b/dev/forward-to-legacy-nginx.yaml @@ -4,7 +4,7 @@ tcp: routers: # Router for HTTPS (Passthrough) nginx-legacy-router-secure: - rule: "HostSNI(`tar.kovagoadi.hu`)" + rule: "HostSNI(`*`)" service: nginx-legacy-service-secure # Passthrough must be true for SSL to reach Nginx encrypted tls: -- 2.49.1 From c35f53315aa5be28b0fbee2fcd721c781ba1f668 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:52:55 +0100 Subject: [PATCH 17/28] Rename back --- docker-compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index dadf7ba..641acc6 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,5 @@ services: - traefik7: + traefik: image: "traefik:v3.6@sha256:67622638cd88dbfcfba40159bc652ecf0aea0e032f8a3c7e3134ae7c037b9910" restart: unless-stopped security_opt: -- 2.49.1 From ee271665d52bf1085f0b0a3505b7a4a5cab9d864 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 15:58:12 +0100 Subject: [PATCH 18/28] Moved to higher priority --- docker-compose.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 641acc6..fc000da 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -40,9 +40,9 @@ services: labels: - "env=${ENV}" - "traefik.enable=true" - - "traefik.http.routers.whoami.priority=100" + - "traefik.http.routers.whoami.priority=1000000" - "traefik.http.routers.whoami.rule=Host(`test-whoami.${DOMAIN}`)" - - "traefik.http.routers.https.priority=100" + - "traefik.http.routers.https.priority=1000000" - "traefik.http.routers.https.rule=Host(`test-whoami.${DOMAIN}`)" - "traefik.http.routers.whoami.entrypoints=web" - traefik.http.routers.https.entrypoints=https -- 2.49.1 From 3ae6abf483460ee795f1b241331c77caecb93bd4 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:01:16 +0100 Subject: [PATCH 19/28] Added only one domain --- dev/forward-to-legacy-nginx.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/forward-to-legacy-nginx.yaml b/dev/forward-to-legacy-nginx.yaml index 4da1e72..ae38952 100644 --- a/dev/forward-to-legacy-nginx.yaml +++ b/dev/forward-to-legacy-nginx.yaml @@ -4,7 +4,7 @@ tcp: routers: # Router for HTTPS (Passthrough) nginx-legacy-router-secure: - rule: "HostSNI(`*`)" + rule: "HostSNI(`tar.kovagoadi.hu`)" service: nginx-legacy-service-secure # Passthrough must be true for SSL to reach Nginx encrypted tls: -- 2.49.1 From fb286883d08960d9cea00115ffb441964ebfbe68 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:10:28 +0100 Subject: [PATCH 20/28] Move to star --- dev/forward-to-legacy-nginx.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/forward-to-legacy-nginx.yaml b/dev/forward-to-legacy-nginx.yaml index ae38952..4da1e72 100644 --- a/dev/forward-to-legacy-nginx.yaml +++ b/dev/forward-to-legacy-nginx.yaml @@ -4,7 +4,7 @@ tcp: routers: # Router for HTTPS (Passthrough) nginx-legacy-router-secure: - rule: "HostSNI(`tar.kovagoadi.hu`)" + rule: "HostSNI(`*`)" service: nginx-legacy-service-secure # Passthrough must be true for SSL to reach Nginx encrypted tls: -- 2.49.1 From fe119171375e6bdcb17a33b1767366a5eff8b9f9 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:17:12 +0100 Subject: [PATCH 21/28] move to one number --- dev/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/route-to-staging-dev.yaml b/dev/route-to-staging-dev.yaml index 0bacc74..da65424 100644 --- a/dev/route-to-staging-dev.yaml +++ b/dev/route-to-staging-dev.yaml @@ -6,7 +6,7 @@ http: entryPoints: - "web" service: "dev-staging" - priority: 1_000_000 + priority: 1000000 # Router for HTTPS (Port 443) staging-secure: -- 2.49.1 From fef0d4f1fb4134f06c9fce3b7cef9585bf460a58 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:33:10 +0100 Subject: [PATCH 22/28] Moved to regexp --- dev/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/route-to-staging-dev.yaml b/dev/route-to-staging-dev.yaml index da65424..7f538d5 100644 --- a/dev/route-to-staging-dev.yaml +++ b/dev/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + rule: "HostRegexp(`^.+\.staging\.kovagoadi\.hu$`) || Host(`staging.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1 From 2966cea94c5b700bd7177853ec47d51b4557c99d Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:36:50 +0100 Subject: [PATCH 23/28] Added the domain hardcoded --- dev/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/route-to-staging-dev.yaml b/dev/route-to-staging-dev.yaml index 7f538d5..f08e4f2 100644 --- a/dev/route-to-staging-dev.yaml +++ b/dev/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "HostRegexp(`^.+\.staging\.kovagoadi\.hu$`) || Host(`staging.kovagoadi.hu`)" + rule: "HostRegexp(`^.+\.staging\.kovagoadi\.hu$`) || Host(`staging.kovagoadi.hu`) || Host(`test-whoami.staging.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1 From 44f73c026d8e66fca97b5b3dd273bf8068b1cb09 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:39:05 +0100 Subject: [PATCH 24/28] Fix mounts --- docker-compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index fc000da..c47b299 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -30,7 +30,7 @@ services: volumes: - "/var/run/docker.sock:/var/run/docker.sock:ro" - "letsencrypt:/letsencrypt" - - "./${ENV}/forward-to-legacy-nginx.yaml:/etc/traefik/forward-to-legacy-nginx.yaml" + - "./${ENV}:/etc/traefik" whoami: image: "traefik/whoami@sha256:200689790a0a0ea48ca45992e0450bc26ccab5307375b41c84dfc4f2475937ab" -- 2.49.1 From 57f5a4ebf9960e0f6e9e1c0abbe53161e55221ae Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:43:59 +0100 Subject: [PATCH 25/28] Changed rule --- dev/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/route-to-staging-dev.yaml b/dev/route-to-staging-dev.yaml index f08e4f2..51fef4f 100644 --- a/dev/route-to-staging-dev.yaml +++ b/dev/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "HostRegexp(`^.+\.staging\.kovagoadi\.hu$`) || Host(`staging.kovagoadi.hu`) || Host(`test-whoami.staging.kovagoadi.hu`)" + rule: "Host(`staging.kovagoadi.hu`) || Host(`test-whoami.staging.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1 From 24867b0fc92f572ac337ef22ecf44e67cb00d267 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:47:48 +0100 Subject: [PATCH 26/28] Move to star --- prod/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index 0bacc74..0d53c5f 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + rule: "Host(`*.staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1 From 1b1356cf360cf4f160bcd1ca3063fbb4bea370ea Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:51:23 +0100 Subject: [PATCH 27/28] Checking with double # --- prod/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index 0d53c5f..1a85cfb 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "Host(`*.staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + rule: "HostRegexp(`^.+\\.staging\\.kovagoadi\\.hu$`) || Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1 From 44d8ae2c5ccd8830fa3f302f685dc50303bb70c2 Mon Sep 17 00:00:00 2001 From: kovagoadi Date: Mon, 22 Dec 2025 16:59:09 +0100 Subject: [PATCH 28/28] Add new Regexp --- prod/route-to-staging-dev.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prod/route-to-staging-dev.yaml b/prod/route-to-staging-dev.yaml index 1a85cfb..1fa3382 100644 --- a/prod/route-to-staging-dev.yaml +++ b/prod/route-to-staging-dev.yaml @@ -2,7 +2,7 @@ http: routers: # Router for HTTP (Port 80) staging: - rule: "HostRegexp(`^.+\\.staging\\.kovagoadi\\.hu$`) || Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" + rule: "HostRegexp({subdomain:.+}.staging.kovagoadi.hu`) || Host(`staging.kovagoadi.hu`) || Host(`dev.kovagoadi.hu`)" entryPoints: - "web" service: "dev-staging" -- 2.49.1