move keycloak_quarkus_proxy_headers into keycloak.conf

This commit is contained in:
Christian Iuga 2024-04-16 13:39:33 +02:00
parent 27717d7b4e
commit 3fbae4882e
2 changed files with 7 additions and 6 deletions

View file

@ -54,9 +54,14 @@ cache-config-file=cache-ispn.xml
{% endif %}
{% if keycloak_quarkus_proxy_mode is defined and keycloak_quarkus_proxy_mode != "none" %}
# Proxy
# Deprecated Proxy configuration
proxy={{ keycloak_quarkus_proxy_mode }}
{% endif %}
{% if keycloak_quarkus_proxy_headers is defined and keycloak_quarkus_proxy_headers != "none" %}
# Proxy
proxy-headers={{ keycloak_quarkus_proxy_headers }}
{% endif %}
spi-sticky-session-encoder-infinispan-should-attach-route={{ keycloak_quarkus_spi_sticky_session_encoder_infinispan_should_attach_route | d(true) | lower }}
# Transaction

View file

@ -7,12 +7,8 @@ After=network.target
Type=simple
EnvironmentFile=-{{ keycloak_quarkus_sysconf_file }}
PIDFile={{ keycloak_quarkus_service_pidfile }}
{% if keycloak_quarkus_start_dev and keycloak_quarkus_proxy_headers is defined %}
ExecStart={{ keycloak.home }}/bin/kc.sh start-dev --proxy-headers {{ keycloak_quarkus_proxy_headers }}
{% elif keycloak_quarkus_start_dev and keycloak_quarkus_proxy_headers is not defined %}
{% if keycloak_quarkus_start_dev %}
ExecStart={{ keycloak.home }}/bin/kc.sh start-dev
{% elif not keycloak_quarkus_start_dev and keycloak_quarkus_proxy_headers is defined %}
ExecStart={{ keycloak.home }}/bin/kc.sh start --optimized --proxy-headers {{ keycloak_quarkus_proxy_headers }}
{% else -%}
ExecStart={{ keycloak.home }}/bin/kc.sh start --optimized
{% endif %}