From f33cd294b5bd83b639c1f853a7df729e14da399a Mon Sep 17 00:00:00 2001 From: Thomas Schaffter Date: Mon, 16 Dec 2024 17:19:36 -0800 Subject: [PATCH] fix(openchallenges): fix OC Caddy routing for `/api` (ARCH-371) (#2949) --- apps/openchallenges/apex/Caddyfile | 1 + docker/openchallenges/services/apex.yml | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/openchallenges/apex/Caddyfile b/apps/openchallenges/apex/Caddyfile index 7d196d094..e1fa908d5 100644 --- a/apps/openchallenges/apex/Caddyfile +++ b/apps/openchallenges/apex/Caddyfile @@ -4,6 +4,7 @@ } handle_path /api* { + rewrite * /api{uri} reverse_proxy {env.API_GATEWAY_HOST}:{env.API_GATEWAY_PORT} } diff --git a/docker/openchallenges/services/apex.yml b/docker/openchallenges/services/apex.yml index 606beecbd..20f44307e 100644 --- a/docker/openchallenges/services/apex.yml +++ b/docker/openchallenges/services/apex.yml @@ -5,8 +5,8 @@ services: restart: always env_file: - ../../../apps/openchallenges/apex/.env - # volumes: - # - ../../../apps/openchallenges/apex/Caddyfile:/etc/caddy/Caddyfile + volumes: + - ../../../apps/openchallenges/apex/Caddyfile:/etc/caddy/Caddyfile networks: - openchallenges ports: