mirror of
https://github.com/bitnami/containers.git
synced 2026-10-22 03:03:10 +02:00
[bitnami/cassandra] Release 5.0.6-debian-12-r9 (#91562)
Signed-off-by: Bitnami Bot <bitnami.bot@broadcom.com>
This commit is contained in:
@@ -8,7 +8,7 @@ ARG JAVA_EXTRA_SECURITY_DIR="/bitnami/java/extra-security"
|
||||
ARG TARGETARCH
|
||||
|
||||
LABEL org.opencontainers.image.base.name="docker.io/bitnami/minideb:bookworm" \
|
||||
org.opencontainers.image.created="2026-03-12T11:39:51Z" \
|
||||
org.opencontainers.image.created="2026-03-12T13:28:27Z" \
|
||||
org.opencontainers.image.description="Application packaged by Broadcom, Inc." \
|
||||
org.opencontainers.image.documentation="https://github.com/bitnami/containers/tree/main/bitnami/cassandra/README.md" \
|
||||
org.opencontainers.image.source="https://github.com/bitnami/containers/tree/main/bitnami/cassandra" \
|
||||
@@ -31,7 +31,7 @@ RUN --mount=type=secret,id=downloads_url,env=SECRET_DOWNLOADS_URL \
|
||||
COMPONENTS=( \
|
||||
"python-3.11.15-2-linux-${OS_ARCH}-debian-12" \
|
||||
"jre-11.0.30-9-1-linux-${OS_ARCH}-debian-12" \
|
||||
"cassandra-5.0.6-1-linux-${OS_ARCH}-debian-12" \
|
||||
"cassandra-5.0.6-2-linux-${OS_ARCH}-debian-12" \
|
||||
) ; \
|
||||
for COMPONENT in "${COMPONENTS[@]}"; do \
|
||||
if [ ! -f "${COMPONENT}.tar.gz" ]; then \
|
||||
@@ -55,7 +55,7 @@ RUN /opt/bitnami/scripts/cassandra/postunpack.sh
|
||||
RUN /opt/bitnami/scripts/java/postunpack.sh
|
||||
ENV APP_VERSION="5.0.6" \
|
||||
BITNAMI_APP_NAME="cassandra" \
|
||||
IMAGE_REVISION="8" \
|
||||
IMAGE_REVISION="9" \
|
||||
JAVA_HOME="/opt/bitnami/java" \
|
||||
PATH="/opt/bitnami/python/bin:/opt/bitnami/java/bin:/opt/bitnami/cassandra/bin:$PATH"
|
||||
|
||||
|
||||
@@ -756,7 +756,11 @@ cassandra_change_cassandra_password() {
|
||||
|
||||
if (echo "ALTER USER cassandra WITH PASSWORD \$\$${escaped_password}\$\$;" | cassandra_execute_with_retries "$retries" "$sleep_time" "$user" "$old_password"); then
|
||||
debug "ALTER USER command executed. Trying to log in"
|
||||
wait_for_cql_access "$user" "$new_password" "localhost" "$retries" "$sleep_time"
|
||||
# ScyllaDB uses 127.0.0.1 explicitly to keep cqlsh on the loopback interface
|
||||
# and avoid the topology-aware reconnect to the pod IP during first-boot init.
|
||||
local cql_host=""
|
||||
[[ "$DB_FLAVOR" = "scylladb" ]] && cql_host="127.0.0.1"
|
||||
wait_for_cql_access "$user" "$new_password" "$cql_host" "$retries" "$sleep_time"
|
||||
info "Password updated successfully"
|
||||
fi
|
||||
}
|
||||
@@ -889,13 +893,27 @@ cassandra_initialize() {
|
||||
info "Deploying $DB_FLAVOR with persisted data"
|
||||
else
|
||||
info "Deploying $DB_FLAVOR from scratch"
|
||||
cassandra_start_bg "$DB_FIRST_BOOT_LOG_FILE"
|
||||
if [[ "$DB_FLAVOR" = "scylladb" ]]; then
|
||||
# ScyllaDB 2025.4.5+ (PR #22532): keep cqlsh on loopback during first-boot init.
|
||||
# Otherwise, cqlsh reconnects to the pod IP (via system.local), blocked by the ensure_superuser_is_created gate.
|
||||
cassandra_start_bg "$DB_FIRST_BOOT_LOG_FILE" "" "" "--broadcast-rpc-address 127.0.0.1"
|
||||
else
|
||||
cassandra_start_bg "$DB_FIRST_BOOT_LOG_FILE"
|
||||
fi
|
||||
if is_boolean_yes "$DB_PASSWORD_SEEDER"; then
|
||||
info "Password seeder node"
|
||||
# Check that all peers are ready
|
||||
for peer in ${DB_PEERS//,/ }; do
|
||||
wait_for_cql_access "cassandra" "cassandra" "$peer" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
done
|
||||
if [[ "$DB_FLAVOR" = "scylladb" ]]; then
|
||||
# ScyllaDB 2025.4.5+ (PR #22532): wait for the superuser record before connecting,
|
||||
# as CQL is accepting connections but auth is not ready until that log line appears.
|
||||
# Use 127.0.0.1 explicitly to prevent cqlsh from reconnecting to the pod IP via system.local.
|
||||
wait_for_superuser_log_entry "$DB_FIRST_BOOT_LOG_FILE" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
wait_for_cql_access "cassandra" "cassandra" "127.0.0.1" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
else
|
||||
# Check that all peers are ready
|
||||
for peer in ${DB_PEERS//,/ }; do
|
||||
wait_for_cql_access "cassandra" "cassandra" "$peer" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
done
|
||||
fi
|
||||
# Setup user
|
||||
if [[ "$DB_USER" = "cassandra" ]]; then
|
||||
cassandra_change_cassandra_password "cassandra" "$DB_PASSWORD" "$DB_CQL_MAX_RETRIES" "$DB_CQL_SLEEP_TIME"
|
||||
@@ -906,8 +924,15 @@ cassandra_initialize() {
|
||||
cassandra_execute_startup_cql
|
||||
else
|
||||
info "Non-seeder node. Waiting for synchronization"
|
||||
wait_for_cql_access "$DB_USER" "$DB_PASSWORD" "localhost" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
# ScyllaDB uses 127.0.0.1 explicitly to keep cqlsh on the loopback interface
|
||||
# and avoid the topology-aware reconnect to the pod IP during first-boot init.
|
||||
local cql_host=""
|
||||
[[ "$DB_FLAVOR" = "scylladb" ]] && cql_host="127.0.0.1"
|
||||
wait_for_cql_access "$DB_USER" "$DB_PASSWORD" "$cql_host" "$DB_PEER_CQL_MAX_RETRIES" "$DB_PEER_CQL_SLEEP_TIME"
|
||||
fi
|
||||
# ScyllaDB is started with '--broadcast-rpc-address 127.0.0.1' for init only;
|
||||
# stop it so the entrypoint can start it cleanly with the real address.
|
||||
[[ "$DB_FLAVOR" = "scylladb" ]] && cassandra_stop
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user