Skip to content

Commit

Permalink
[bitnami/keycloak] use hostname v2
Browse files Browse the repository at this point in the history
Signed-off-by: Baljit Singh <[email protected]>
  • Loading branch information
singhbaljit committed Jul 31, 2024
1 parent bb31050 commit 3f3a0b3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ keycloak_env_vars=(
KEYCLOAK_HTTPS_PORT
KEYCLOAK_BIND_ADDRESS
KEYCLOAK_HOSTNAME
KEYCLOAK_HOSTNAME_ADMIN
KEYCLOAK_INIT_MAX_RETRIES
KEYCLOAK_CACHE_TYPE
KEYCLOAK_CACHE_STACK
Expand Down Expand Up @@ -131,6 +132,8 @@ export KEYCLOAK_HTTPS_PORT="${KEYCLOAK_HTTPS_PORT:-8443}"
export KEYCLOAK_BIND_ADDRESS="${KEYCLOAK_BIND_ADDRESS:-$(hostname --fqdn)}"
KEYCLOAK_HOSTNAME="${KEYCLOAK_HOSTNAME:-"${KC_HOSTNAME:-}"}"
export KEYCLOAK_HOSTNAME="${KEYCLOAK_HOSTNAME:-}"
KEYCLOAK_HOSTNAME_ADMIN="${KEYCLOAK_HOSTNAME_ADMIN:-"${KC_HOSTNAME_ADMIN:-}"}"
export KEYCLOAK_HOSTNAME_ADMIN="${KEYCLOAK_HOSTNAME_ADMIN:-}"
export KEYCLOAK_INIT_MAX_RETRIES="${KEYCLOAK_INIT_MAX_RETRIES:-10}"
export KEYCLOAK_CACHE_TYPE="${KEYCLOAK_CACHE_TYPE:-ispn}"
export KEYCLOAK_CACHE_STACK="${KEYCLOAK_CACHE_STACK:-}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ keycloak_configure_health_endpoints() {
keycloak_configure_hostname() {
info "Configuring hostname settings"
! is_empty_value "$KEYCLOAK_HOSTNAME" && keycloak_conf_set "hostname" "${KEYCLOAK_HOSTNAME}"
keycloak_conf_set "hostname-strict" "false"
! is_empty_value "$KEYCLOAK_HOSTNAME_ADMIN" && keycloak_conf_set "hostname-admin" "${KEYCLOAK_HOSTNAME_ADMIN}"
}

########################
Expand Down
1 change: 1 addition & 0 deletions bitnami/keycloak/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ docker build -t bitnami/APP:latest .
| `KEYCLOAK_HTTPS_PORT` | HTTPS port | `8443` |
| `KEYCLOAK_BIND_ADDRESS` | Bind address | `$(hostname --fqdn)` |
| `KEYCLOAK_HOSTNAME` | Keycloak hostname | `nil` |
| `KEYCLOAK_HOSTNAME_ADMIN` | Keycloak admin hostname | `nil` |
| `KEYCLOAK_INIT_MAX_RETRIES` | Maximum retries for checking that the database works | `10` |
| `KEYCLOAK_CACHE_TYPE` | Defines the cache mechanism for high-availability. | `ispn` |
| `KEYCLOAK_CACHE_STACK` | Apply a specific cache stack | `nil` |
Expand Down

0 comments on commit 3f3a0b3

Please sign in to comment.