From 2e82ca3a9fde2238dccddade5a4c5b2fc8ba00da Mon Sep 17 00:00:00 2001 From: Saibotk Date: Wed, 14 Aug 2024 01:08:03 +0200 Subject: [PATCH] feat(keycloak): use persistend sessions & use new options Replace deprecated PROXY setting, see https://github.com/keycloak/keycloak/issues/29665 --- roles/keycloak/templates/docker-compose.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/roles/keycloak/templates/docker-compose.yml b/roles/keycloak/templates/docker-compose.yml index 8eb4686..93245c8 100644 --- a/roles/keycloak/templates/docker-compose.yml +++ b/roles/keycloak/templates/docker-compose.yml @@ -40,9 +40,11 @@ services: {% endif %} environment: - - "KC_PROXY=edge" - - "KC_FEATURES=scripts" - - "KC_HOSTNAME={{ keycloak_domain }}" + - "KC_PROXY_HEADERs=xforwarded" + - "KC_HTTP_ENABLED=true" + - "KC_FEATURES=scripts,persistent-user-session" + - "KC_HOSTNAME_STRICT=true" + - "KC_HOSTNAME=https://{{ keycloak_domain }}" - "KC_LOGLEVEL={{ keycloak_log_level }}" - "KC_DB_URL_HOST=database" - "KC_DB_USERNAME={{ keycloak_database_user }}"