diff --git a/config/docker/caddy/web-app/Caddyfile b/config/docker/caddy/web-app/Caddyfile index 66e46c47..89400b3c 100644 --- a/config/docker/caddy/web-app/Caddyfile +++ b/config/docker/caddy/web-app/Caddyfile @@ -22,7 +22,7 @@ # Caddy-Template-Engine: ersetzt {{.Env.VAR}} in index.html UND config.json templates { - mime text/html application/json + mime application/json } # API-Proxy (höchste Priorität – vor dem SPA-Fallback) diff --git a/frontend/shells/meldestelle-portal/src/jsMain/resources/index.html b/frontend/shells/meldestelle-portal/src/jsMain/resources/index.html index fd5c423f..f65e9afb 100644 --- a/frontend/shells/meldestelle-portal/src/jsMain/resources/index.html +++ b/frontend/shells/meldestelle-portal/src/jsMain/resources/index.html @@ -27,7 +27,7 @@ ? apiOverride.replace(/\/$/, '') : (apiFromCaddy && !apiFromCaddy.startsWith('{{') ? apiFromCaddy.replace(/\/$/, '') - : 'https://' + window.location.origin.replace(/\/$/, '')); + : 'http://' + window.location.origin.replace(/\/$/, '')); // Caddy injiziert: {{.Env.KEYCLOAK_URL}} → z.B. "https://auth.mo-code.at" const kcFromCaddy = '{{.Env.KEYCLOAK_URL}}'; @@ -36,7 +36,7 @@ ? kcOverride.replace(/\/$/, '') : (kcFromCaddy && !kcFromCaddy.startsWith('{{') ? kcFromCaddy.replace(/\/$/, '') - : 'https://' + window.location.hostname + ':8180'); + : 'http://' + window.location.hostname + ':8180'); } catch (e) { globalThis.API_BASE_URL = 'http://localhost:8081';