Update Keycloak to use v2 proxy headers (KC_PROXY_HEADERS)

- Replace deprecated KC_PROXY=edge with KC_PROXY_HEADERS=xforwarded
- Fixes 'Hostname v1 options [proxy] are still in use' warning
- Convert docker-compose-keycloak.yml to use .env file
- Remove hardcoded passwords from docker-compose.yml
- Add comprehensive .env template in comments
- Update deployment instructions and production checklist
- Resolves CORS and secure context warnings
- All credentials now in .env with proper security
This commit is contained in:
Claude
2026-01-13 03:39:08 +00:00
parent 6098bbc209
commit 736c53b1db
2 changed files with 44 additions and 49 deletions
+2 -1
View File
@@ -3758,7 +3758,8 @@ KC_DB_USERNAME=keycloak
KC_DB_PASSWORD=$KC_DB_PASS
# Keycloak Configuration
KC_PROXY=edge
# Proxy settings (v2) - Trust X-Forwarded-* headers from Caddy2
KC_PROXY_HEADERS=xforwarded
KC_HTTP_ENABLED=true
KC_HOSTNAME_STRICT=$KC_HOSTNAME_STRICT
KC_LOG_LEVEL=INFO