mirror of
https://github.com/bitnami/containers.git
synced 2026-03-29 16:27:49 +08:00
[bitnami/keycloak] Release 19.0.2-debian-11-r0 (#6366)
Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com> Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com>
This commit is contained in:
@@ -5,11 +5,11 @@ ARG TARGETARCH
|
||||
|
||||
LABEL org.opencontainers.image.authors="https://bitnami.com/contact" \
|
||||
org.opencontainers.image.description="Application packaged by Bitnami" \
|
||||
org.opencontainers.image.ref.name="19.0.1-debian-11-r2" \
|
||||
org.opencontainers.image.ref.name="19.0.2-debian-11-r0" \
|
||||
org.opencontainers.image.source="https://github.com/bitnami/containers/tree/main/bitnami/keycloak" \
|
||||
org.opencontainers.image.title="keycloak" \
|
||||
org.opencontainers.image.vendor="VMware, Inc." \
|
||||
org.opencontainers.image.version="19.0.1"
|
||||
org.opencontainers.image.version="19.0.2"
|
||||
|
||||
ENV HOME="/" \
|
||||
OS_ARCH="${TARGETARCH:-amd64}" \
|
||||
@@ -37,13 +37,13 @@ RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
||||
tar -zxf java-11.0.15-1-3-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
||||
rm -rf java-11.0.15-1-3-linux-${OS_ARCH}-debian-11.tar.gz java-11.0.15-1-3-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
||||
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
||||
if [ ! -f keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
||||
curl -SsLf https://downloads.bitnami.com/files/stacksmith/keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
||||
curl -SsLf https://downloads.bitnami.com/files/stacksmith/keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
||||
if [ ! -f keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
||||
curl -SsLf https://downloads.bitnami.com/files/stacksmith/keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
||||
curl -SsLf https://downloads.bitnami.com/files/stacksmith/keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 -O ; \
|
||||
fi && \
|
||||
sha256sum -c keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
||||
tar -zxf keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
||||
rm -rf keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz keycloak-19.0.1-3-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
||||
sha256sum -c keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256 && \
|
||||
tar -zxf keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz -C /opt/bitnami --strip-components=2 --no-same-owner --wildcards '*/files' && \
|
||||
rm -rf keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz keycloak-19.0.2-0-linux-${OS_ARCH}-debian-11.tar.gz.sha256
|
||||
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
||||
if [ ! -f gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz ]; then \
|
||||
curl -SsLf https://downloads.bitnami.com/files/stacksmith/gosu-1.14.0-154-linux-${OS_ARCH}-debian-11.tar.gz -O ; \
|
||||
@@ -59,7 +59,7 @@ RUN chmod g+rwX /opt/bitnami
|
||||
COPY rootfs /
|
||||
RUN /opt/bitnami/scripts/java/postunpack.sh
|
||||
RUN /opt/bitnami/scripts/keycloak/postunpack.sh
|
||||
ENV APP_VERSION="19.0.1" \
|
||||
ENV APP_VERSION="19.0.2" \
|
||||
BITNAMI_APP_NAME="keycloak" \
|
||||
JAVA_HOME="/opt/bitnami/java" \
|
||||
PATH="/opt/bitnami/common/bin:/opt/bitnami/java/bin:/opt/bitnami/keycloak/bin:$PATH"
|
||||
|
||||
@@ -15,10 +15,10 @@
|
||||
},
|
||||
"keycloak": {
|
||||
"arch": "amd64",
|
||||
"digest": "5093005c4cdc78689a5390dd63568b3e94d076e08577e23de131a1a278d0c7a7",
|
||||
"digest": "2688d903cd848df64dc563ccec4a8f5f49a206b43a7514005d6458c9d52f16c2",
|
||||
"distro": "debian-11",
|
||||
"type": "NAMI",
|
||||
"version": "19.0.1-3"
|
||||
"version": "19.0.2-0"
|
||||
},
|
||||
"wait-for-port": {
|
||||
"arch": "amd64",
|
||||
|
||||
@@ -170,18 +170,19 @@ configure_permissions_ownership() {
|
||||
read -r -a filepaths <<<"$paths"
|
||||
for p in "${filepaths[@]}"; do
|
||||
if [[ -e "$p" ]]; then
|
||||
find -L "$p" -printf ""
|
||||
if [[ -n $dir_mode ]]; then
|
||||
find -L "$p" -type d -exec chmod "$dir_mode" {} \;
|
||||
find -L "$p" -type d ! -perm "$dir_mode" -print0 | xargs -r -0 chmod "$dir_mode"
|
||||
fi
|
||||
if [[ -n $file_mode ]]; then
|
||||
find -L "$p" -type f -exec chmod "$file_mode" {} \;
|
||||
find -L "$p" -type f ! -perm "$file_mode" -print0 | xargs -r -0 chmod "$file_mode"
|
||||
fi
|
||||
if [[ -n $user ]] && [[ -n $group ]]; then
|
||||
chown -LR "$user":"$group" "$p"
|
||||
find -L "$p" -print0 | xargs -r -0 chown "${user}:${group}"
|
||||
elif [[ -n $user ]] && [[ -z $group ]]; then
|
||||
chown -LR "$user" "$p"
|
||||
find -L "$p" -print0 | xargs -r -0 chown "${user}"
|
||||
elif [[ -z $user ]] && [[ -n $group ]]; then
|
||||
chgrp -LR "$group" "$p"
|
||||
find -L "$p" -print0 | xargs -r -0 chgrp "${group}"
|
||||
fi
|
||||
else
|
||||
stderr_print "$p does not exist"
|
||||
|
||||
@@ -464,3 +464,37 @@ convert_to_hex() {
|
||||
printf '%x' "'${char}"
|
||||
done
|
||||
}
|
||||
|
||||
########################
|
||||
# Get boot time
|
||||
# Globals:
|
||||
# None
|
||||
# Arguments:
|
||||
# None
|
||||
# Returns:
|
||||
# Boot time metadata
|
||||
#########################
|
||||
get_boot_time() {
|
||||
stat /proc --format=%Y
|
||||
}
|
||||
|
||||
########################
|
||||
# Get machine ID
|
||||
# Globals:
|
||||
# None
|
||||
# Arguments:
|
||||
# None
|
||||
# Returns:
|
||||
# Machine ID
|
||||
#########################
|
||||
get_machine_id() {
|
||||
local machine_id
|
||||
if [[ -f /etc/machine-id ]]; then
|
||||
machine_id="$(cat /etc/machine-id)"
|
||||
fi
|
||||
if [[ -z "$machine_id" ]]; then
|
||||
# Fallback to the boot-time, which will at least ensure a unique ID in the current session
|
||||
machine_id="$(get_boot_time)"
|
||||
fi
|
||||
echo "$machine_id"
|
||||
}
|
||||
|
||||
@@ -271,3 +271,140 @@ remove_logrotate_conf() {
|
||||
local logrotate_conf_dir="/etc/logrotate.d"
|
||||
rm -f "${logrotate_conf_dir}/${service_name}"
|
||||
}
|
||||
|
||||
########################
|
||||
# Generate a Systemd configuration file
|
||||
# Arguments:
|
||||
# $1 - Service name
|
||||
# Flags:
|
||||
# --exec-start - Start command (required)
|
||||
# --exec-stop - Stop command (optional)
|
||||
# --exec-reload - Reload command (optional)
|
||||
# --name - Service full name (e.g. Apache HTTP Server, defaults to $1)
|
||||
# --restart - When to restart the Systemd service after being stopped (defaults to always)
|
||||
# --pid-file - Service PID file (required when --restart is set to always)
|
||||
# --type - Systemd unit type (defaults to forking)
|
||||
# --user - System user to start the service with
|
||||
# --group - System group to start the service with
|
||||
# --environment - Environment variable to define (multiple --environment options may be passed)
|
||||
# Returns:
|
||||
# None
|
||||
#########################
|
||||
generate_systemd_conf() {
|
||||
local -r service_name="${1:?service name is missing}"
|
||||
local -r systemd_units_dir="/etc/systemd/system"
|
||||
local -r service_file="${systemd_units_dir}/bitnami.${service_name}.service"
|
||||
# Default values
|
||||
local name="$service_name"
|
||||
local type="forking"
|
||||
local user=""
|
||||
local group=""
|
||||
local environment=""
|
||||
local exec_start=""
|
||||
local exec_stop=""
|
||||
local exec_reload=""
|
||||
local restart="always"
|
||||
local pid_file=""
|
||||
# Parse CLI flags
|
||||
shift
|
||||
while [[ "$#" -gt 0 ]]; do
|
||||
case "$1" in
|
||||
--name \
|
||||
| --type \
|
||||
| --user \
|
||||
| --group \
|
||||
| --exec-start \
|
||||
| --exec-stop \
|
||||
| --exec-reload \
|
||||
| --restart \
|
||||
| --pid-file \
|
||||
)
|
||||
var_name="$(echo "$1" | sed -e "s/^--//" -e "s/-/_/g")"
|
||||
shift
|
||||
declare "$var_name"="${1:?"$var_name" is missing}"
|
||||
;;
|
||||
--environment)
|
||||
shift
|
||||
# It is possible to add multiple environment lines
|
||||
[[ -n "$environment" ]] && environment+=$'\n'
|
||||
environment+="Environment=${1:?"environment" is missing}"
|
||||
;;
|
||||
*)
|
||||
echo "Invalid command line flag ${1}" >&2
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
# Validate inputs
|
||||
local error="no"
|
||||
if [[ -z "$exec_start" ]]; then
|
||||
error "The --exec-start option is required"
|
||||
error="yes"
|
||||
fi
|
||||
if [[ "$restart" = "always" && -z "$pid_file" ]]; then
|
||||
error "The --restart option cannot be set to 'always' if --pid-file is not set"
|
||||
error="yes"
|
||||
fi
|
||||
if [[ "$error" != "no" ]]; then
|
||||
return 1
|
||||
fi
|
||||
# Generate the Systemd unit
|
||||
cat > "$service_file" <<EOF
|
||||
[Unit]
|
||||
Description=Bitnami service for ${name}
|
||||
# Starting/stopping the main bitnami service should cause the same effect for this service
|
||||
PartOf=bitnami.service
|
||||
|
||||
[Service]
|
||||
Type=${type}
|
||||
ExecStart=${exec_start}
|
||||
EOF
|
||||
# Optional stop and reload commands
|
||||
if [[ -n "$exec_stop" ]]; then
|
||||
cat >> "$service_file" <<EOF
|
||||
ExecStop=${exec_stop}
|
||||
EOF
|
||||
fi
|
||||
if [[ -n "$exec_reload" ]]; then
|
||||
cat >> "$service_file" <<EOF
|
||||
ExecReload=${exec_reload}
|
||||
EOF
|
||||
fi
|
||||
# User and group
|
||||
if [[ -n "$user" ]]; then
|
||||
cat >> "$service_file" <<EOF
|
||||
User=${user}
|
||||
EOF
|
||||
fi
|
||||
if [[ -n "$group" ]]; then
|
||||
cat >> "$service_file" <<EOF
|
||||
Group=${group}
|
||||
EOF
|
||||
fi
|
||||
# PID file allows to determine if the main process is running properly (for Restart=always)
|
||||
if [[ -n "$pid_file" ]]; then
|
||||
cat >> "$service_file" <<EOF
|
||||
PIDFile=${pid_file}
|
||||
EOF
|
||||
fi
|
||||
# Environment flags (may be specified multiple times in a unit)
|
||||
if [[ -n "$environment" ]]; then
|
||||
cat >> "$service_file" <<< "$environment"
|
||||
fi
|
||||
cat >> "$service_file" <<EOF
|
||||
Restart=${restart}
|
||||
# Optimizations
|
||||
TimeoutSec=5min
|
||||
IgnoreSIGPIPE=no
|
||||
KillMode=mixed
|
||||
# Limits
|
||||
LimitNOFILE=infinity
|
||||
# Configure output to appear in instance console output
|
||||
StandardOutput=journal+console
|
||||
|
||||
[Install]
|
||||
# Enabling/disabling the main bitnami service should cause the same effect for this service
|
||||
WantedBy=bitnami.service
|
||||
EOF
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
rolling-tags:
|
||||
- "19"
|
||||
- "19-debian-11"
|
||||
- "19.0.1"
|
||||
- "19.0.2"
|
||||
- "latest"
|
||||
|
||||
@@ -44,7 +44,7 @@ Non-root container images add an extra layer of security and are generally recom
|
||||
Learn more about the Bitnami tagging policy and the difference between rolling tags and immutable tags [in our documentation page](https://docs.bitnami.com/tutorials/understand-rolling-tags-containers/).
|
||||
|
||||
|
||||
* [`19`, `19-debian-11`, `19.0.1`, `19.0.1-debian-11-r2`, `latest` (19/debian-11/Dockerfile)](https://github.com/bitnami/containers/blob/main/bitnami/keycloak/19/debian-11/Dockerfile)
|
||||
* [`19`, `19-debian-11`, `19.0.2`, `19.0.2-debian-11-r0`, `latest` (19/debian-11/Dockerfile)](https://github.com/bitnami/containers/blob/main/bitnami/keycloak/19/debian-11/Dockerfile)
|
||||
* [`18`, `18-debian-11`, `18.0.2`, `18.0.2-debian-11-r28` (18/debian-11/Dockerfile)](https://github.com/bitnami/containers/blob/main/bitnami/keycloak/18/debian-11/Dockerfile)
|
||||
|
||||
Subscribe to project updates by watching the [bitnami/containers GitHub repo](https://github.com/bitnami/containers).
|
||||
@@ -214,6 +214,10 @@ After that, your changes will be taken into account in the server's behaviour.
|
||||
Keycloak 17 is powered by Quarkus and to deploy it in production mode it is necessary to set up TLS.
|
||||
To do this you need to set `KEYCLOAK_PRODUCTION` to **true** and configure TLS
|
||||
|
||||
## Branch Deprecation Notice
|
||||
|
||||
Keycloak's branch 18 is no longer maintained by upstream and is now internally tagged as to be deprecated. This branch will no longer be released in our catalog a month after this notice is published, but already released container images will still persist in the registries. Valid to be removed starting on: 10-12-2022
|
||||
|
||||
## Contributing
|
||||
|
||||
We'd love for you to contribute to this container. You can request new features by creating an [issue](https://github.com/bitnami/containers/issues), or submit a [pull request](https://github.com/bitnami/containers/pulls) with your contribution.
|
||||
|
||||
Reference in New Issue
Block a user