From 6d0568e9de261ccc979a84187a14b3bf3ae127f6 Mon Sep 17 00:00:00 2001 From: Bitnami Bot Date: Mon, 25 May 2026 08:36:28 +0200 Subject: [PATCH] [bitnami/etcd] Release 3.6.11-debian-12-r5 (#93969) Signed-off-by: Bitnami Bot --- bitnami/etcd/3.6/debian-12/Dockerfile | 4 +-- .../opt/bitnami/scripts/etcd/healthcheck.sh | 3 +- .../opt/bitnami/scripts/etcd/preupgrade.sh | 3 +- .../opt/bitnami/scripts/etcd/snapshot.sh | 3 +- .../rootfs/opt/bitnami/scripts/libetcd.sh | 34 +++++++------------ 5 files changed, 20 insertions(+), 27 deletions(-) diff --git a/bitnami/etcd/3.6/debian-12/Dockerfile b/bitnami/etcd/3.6/debian-12/Dockerfile index 80ec56c3aa0b..31c0ee2a0952 100644 --- a/bitnami/etcd/3.6/debian-12/Dockerfile +++ b/bitnami/etcd/3.6/debian-12/Dockerfile @@ -7,7 +7,7 @@ ARG DOWNLOADS_URL="downloads.bitnami.com/files/stacksmith" ARG TARGETARCH LABEL org.opencontainers.image.base.name="docker.io/bitnami/minideb:bookworm" \ - org.opencontainers.image.created="2026-05-23T07:38:19Z" \ + org.opencontainers.image.created="2026-05-25T06:28:06Z" \ org.opencontainers.image.description="Application packaged by Broadcom, Inc." \ org.opencontainers.image.documentation="https://github.com/bitnami/containers/tree/main/bitnami/etcd/README.md" \ org.opencontainers.image.source="https://github.com/bitnami/containers/tree/main/bitnami/etcd" \ @@ -50,7 +50,7 @@ COPY rootfs / RUN /opt/bitnami/scripts/etcd/postunpack.sh ENV APP_VERSION="3.6.11" \ BITNAMI_APP_NAME="etcd" \ - IMAGE_REVISION="4" \ + IMAGE_REVISION="5" \ PATH="/opt/bitnami/common/bin:/opt/bitnami/etcd/bin:$PATH" EXPOSE 2379 2380 diff --git a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/healthcheck.sh b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/healthcheck.sh index b092e149318b..da546acc9b17 100755 --- a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/healthcheck.sh +++ b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/healthcheck.sh @@ -19,7 +19,8 @@ set -o nounset read -r -a advertised_array <<< "$(tr ',;' ' ' <<< "$ETCD_ADVERTISE_CLIENT_URLS")" host="$(parse_uri "${advertised_array[0]}" "host")" port="$(parse_uri "${advertised_array[0]}" "port")" -read -r -a extra_flags <<< "$(etcdctl_auth_flags)" +read -r -a extra_flags <<< "$(etcdctl_auth_norbac_flags)" +! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" extra_flags+=("--endpoints=${host}:${port}") # if ETCD_AUTO_TLS true or CA file not exists, just skip server cert verification diff --git a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/preupgrade.sh b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/preupgrade.sh index 56b1b5d9779a..2197e36077c1 100755 --- a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/preupgrade.sh +++ b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/preupgrade.sh @@ -35,7 +35,8 @@ endpoints_as_host_port() { # from the cluster before running Helm upgrades that potentially scale # down the etcd cluster -read -r -a extra_flags <<<"$(etcdctl_auth_flags)" +read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" +! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" is_boolean_yes "$ETCD_ON_K8S" && extra_flags+=("--endpoints=$(endpoints_as_host_port)") if [[ -n "$ETCD_PREUPGRADE_START_DELAY" ]]; then diff --git a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/snapshot.sh b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/snapshot.sh index 7bf2f541cd44..c65dd58620c8 100755 --- a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/snapshot.sh +++ b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/etcd/snapshot.sh @@ -21,7 +21,8 @@ endpoints="$(etcdctl_get_endpoints)" read -r -a endpoints_array <<< "$(tr ',;' ' ' <<< "$endpoints")" for e in "${endpoints_array[@]}"; do debug "Using endpoint $e" - read -r -a extra_flags <<< "$(etcdctl_auth_flags)" + read -r -a extra_flags <<< "$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" extra_flags+=("--endpoints=$e") if etcdctl endpoint health "${extra_flags[@]}"; then info "Snapshotting the keyspace" diff --git a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/libetcd.sh b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/libetcd.sh index 55c4a862d2ea..1029b948f4bd 100644 --- a/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/libetcd.sh +++ b/bitnami/etcd/3.6/debian-12/rootfs/opt/bitnami/scripts/libetcd.sh @@ -263,22 +263,6 @@ etcdctl_get_endpoints() { echo "${endpoints[*]}" | tr ' ' ',' } -######################## -# Obtain etcdctl authentication flags to use -# Globals: -# ETCD_* -# Arguments: -# None -# Returns: -# Array with extra flags to use for authentication -######################### -etcdctl_auth_flags() { - local -a authFlags=() - - ! is_empty_value "$ETCD_ROOT_PASSWORD" && authFlags+=("--user" "root:$ETCD_ROOT_PASSWORD") - echo "${authFlags[*]} $(etcdctl_auth_norbac_flags)" -} - ######################## # Obtain etcdctl authentication flags to use (before RBAC is enabled) # Globals: @@ -346,7 +330,8 @@ etcd_configure_rbac() { ######################## is_new_etcd_cluster() { local -a extra_flags - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" is_boolean_yes "$ETCD_ON_K8S" && extra_flags+=("--endpoints=$(etcdctl_get_endpoints)") ! debug_execute etcdctl endpoint status --cluster "${extra_flags[@]}" } @@ -373,7 +358,8 @@ setup_etcd_active_endpoints() { port="$(parse_uri "${advertised_array[0]}" "port")" if [[ $cluster_size -gt 0 ]]; then for e in "${endpoints_array[@]}"; do - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" extra_flags+=("--endpoints=$e") if [[ "$e" != "$host:$port" ]] && etcdctl endpoint health "${extra_flags[@]}" >/dev/null 2>&1; then debug "$e endpoint is active" @@ -494,7 +480,8 @@ remove_old_member_if_exist() { if ! is_empty_value "$old_member_id"; then info "Removing old member $old_member_id" local -a extra_flags - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" is_boolean_yes "$ETCD_ON_K8S" && extra_flags+=("--endpoints=$(etcdctl_get_endpoints)") etcdctl member remove "$old_member_id" "${extra_flags[@]}" fi @@ -512,7 +499,8 @@ remove_old_member_if_exist() { add_new_member() { info "Adding new member to existing cluster" local -a extra_flags - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" is_boolean_yes "$ETCD_ON_K8S" && extra_flags+=("--endpoints=$(etcdctl_get_endpoints)") extra_flags+=("--peer-urls=$ETCD_INITIAL_ADVERTISE_PEER_URLS") mkdir -p "$(dirname $ETCD_NEW_MEMBERS_ENV_FILE)" || true @@ -731,7 +719,6 @@ etcd_initialize() { ######################### add_self_to_cluster() { local -a extra_flags - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" # is_healthy_etcd_cluster will also set ETCD_ACTIVE_ENDPOINTS while ! is_healthy_etcd_cluster; do warn "Cluster not healthy, not adding self to cluster for now, keeping trying..." @@ -741,7 +728,9 @@ add_self_to_cluster() { # only send req to healthy nodes if is_empty_value "$(get_member_id)"; then + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" extra_flags+=("--endpoints=${ETCD_ACTIVE_ENDPOINTS}" "--peer-urls=$ETCD_INITIAL_ADVERTISE_PEER_URLS") + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" while ! etcdctl member add "$ETCD_NAME" "${extra_flags[@]}" | grep "^ETCD_" >"$ETCD_NEW_MEMBERS_ENV_FILE"; do warn "Failed to add self to cluster, keeping trying..." sleep 10 @@ -768,7 +757,8 @@ get_member_id() { local ret local -a extra_flags - read -r -a extra_flags <<<"$(etcdctl_auth_flags)" + read -r -a extra_flags <<<"$(etcdctl_auth_norbac_flags)" + ! is_empty_value "$ETCD_ROOT_PASSWORD" && export ETCDCTL_USER="root:$ETCD_ROOT_PASSWORD" is_boolean_yes "$ETCD_ON_K8S" && extra_flags+=("--endpoints=$(etcdctl_get_endpoints)") ret=$(etcdctl "${extra_flags[@]}" member list | grep -w "$ETCD_INITIAL_ADVERTISE_PEER_URLS" | awk -F "," '{ print $1 }') # if not return zero