# ============================================================================= # tOS Caddy Reverse Proxy Konfiguration # ============================================================================= # Caddy uebernimmt automatisch Let's Encrypt Zertifikate und HTTPS-Terminierung. # # Routing: # {APP_DOMAIN} -> Web Frontend (Next.js) # {APP_DOMAIN}/api/* -> API Backend (NestJS) # auth.{APP_DOMAIN} -> Keycloak Identity Provider # ============================================================================= { email {$LETSENCRYPT_EMAIL} } # Haupt-Domain: Frontend + API {$APP_DOMAIN} { # API-Requests an das NestJS Backend weiterleiten handle /api/* { reverse_proxy api:3001 } # Alle anderen Requests an das Next.js Frontend reverse_proxy web:3000 } # Auth-Subdomain: Keycloak auth.{$APP_DOMAIN} { reverse_proxy keycloak:8080 }