mirror of
https://github.com/bitnami/containers.git
synced 2026-10-18 09:28:09 +02:00
[bitnami/airflow] Release 3.2.1-debian-12-r0 (#92648)
Signed-off-by: Bitnami Bot <bitnami.bot@broadcom.com>
This commit is contained in:
@@ -7,13 +7,13 @@ 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-04-17T18:53:21Z" \
|
||||
org.opencontainers.image.created="2026-04-25T17:02:59Z" \
|
||||
org.opencontainers.image.description="Application packaged by Broadcom, Inc." \
|
||||
org.opencontainers.image.documentation="https://github.com/bitnami/containers/tree/main/bitnami/airflow/README.md" \
|
||||
org.opencontainers.image.source="https://github.com/bitnami/containers/tree/main/bitnami/airflow" \
|
||||
org.opencontainers.image.title="airflow" \
|
||||
org.opencontainers.image.vendor="Broadcom, Inc." \
|
||||
org.opencontainers.image.version="3.2.0"
|
||||
org.opencontainers.image.version="3.2.1"
|
||||
|
||||
ENV HOME="/" \
|
||||
OS_ARCH="${TARGETARCH:-amd64}" \
|
||||
@@ -28,12 +28,12 @@ RUN --mount=type=secret,id=downloads_url,env=SECRET_DOWNLOADS_URL \
|
||||
DOWNLOADS_URL=${SECRET_DOWNLOADS_URL:-${DOWNLOADS_URL}} ; \
|
||||
mkdir -p /tmp/bitnami/pkg/cache/ ; cd /tmp/bitnami/pkg/cache/ || exit 1 ; \
|
||||
COMPONENTS=( \
|
||||
"python-3.12.13-7-linux-${OS_ARCH}-debian-12" \
|
||||
"nss-wrapper-1.1.16-0-linux-${OS_ARCH}-debian-12" \
|
||||
"ini-file-1.4.9-9-linux-${OS_ARCH}-debian-12" \
|
||||
"wait-for-port-1.0.10-9-linux-${OS_ARCH}-debian-12" \
|
||||
"mariadb-lib-12.2.2-3-linux-${OS_ARCH}-debian-12" \
|
||||
"airflow-3.2.0-0-linux-${OS_ARCH}-debian-12" \
|
||||
"python-3.12.13-7-linux-${OS_ARCH}-debian-12" \
|
||||
"airflow-3.2.1-0-linux-${OS_ARCH}-debian-12" \
|
||||
) ; \
|
||||
for COMPONENT in "${COMPONENTS[@]}"; do \
|
||||
if [ ! -f "${COMPONENT}.tar.gz" ]; then \
|
||||
@@ -58,7 +58,7 @@ RUN uninstall_packages curl
|
||||
COPY rootfs /
|
||||
RUN /opt/bitnami/scripts/airflow/postunpack.sh
|
||||
ENV AIRFLOW_HOME="/opt/bitnami/airflow" \
|
||||
APP_VERSION="3.2.0" \
|
||||
APP_VERSION="3.2.1" \
|
||||
BITNAMI_APP_NAME="airflow" \
|
||||
IMAGE_REVISION="0" \
|
||||
LANG="en_US.UTF-8" \
|
||||
@@ -68,7 +68,7 @@ ENV AIRFLOW_HOME="/opt/bitnami/airflow" \
|
||||
LNAME="airflow" \
|
||||
NSS_WRAPPER_GROUP="/opt/bitnami/airflow/nss-wrapper/nss_group" \
|
||||
NSS_WRAPPER_PASSWD="/opt/bitnami/airflow/nss-wrapper/nss_passwd" \
|
||||
PATH="/opt/bitnami/common/bin:/opt/bitnami/airflow/venv/bin:/opt/bitnami/python/bin:$PATH"
|
||||
PATH="/opt/bitnami/python/bin:/opt/bitnami/common/bin:/opt/bitnami/airflow/venv/bin:$PATH"
|
||||
|
||||
EXPOSE 8080 8125 8793 8794
|
||||
|
||||
|
||||
@@ -17,8 +17,6 @@ set -o pipefail
|
||||
. /opt/bitnami/scripts/libairflow.sh
|
||||
|
||||
command=("$AIRFLOW_COMPONENT_TYPE")
|
||||
# 2.x and 3.x compatibility
|
||||
[[ "$AIRFLOW_COMPONENT_TYPE" = "api-server" ]] && [[ $(airflow_major_version) -eq 2 ]] && command=("webserver")
|
||||
args=("--pid" "${AIRFLOW_TMP_DIR}/airflow-${AIRFLOW_COMPONENT_TYPE}.pid" "$@")
|
||||
if [[ "$AIRFLOW_COMPONENT_TYPE" = "worker" ]]; then
|
||||
command=("celery" "worker")
|
||||
|
||||
@@ -186,10 +186,6 @@ airflow_initialize() {
|
||||
|
||||
local db_init_command="migrate"
|
||||
local db_upgrade_command="migrate"
|
||||
if [[ $(airflow_major_version) -eq 2 ]]; then
|
||||
db_init_command="init"
|
||||
db_upgrade_command="upgrade"
|
||||
fi
|
||||
case "$AIRFLOW_COMPONENT_TYPE" in
|
||||
webserver|api-server)
|
||||
# Remove pid file if exists to prevent error after WSL restarts
|
||||
@@ -289,20 +285,13 @@ airflow_generate_config() {
|
||||
*)
|
||||
# Generate Airflow default files
|
||||
debug_execute airflow config list --defaults > "${AIRFLOW_CONF_FILE}"
|
||||
if [[ $(airflow_major_version) -ne 2 ]]; then
|
||||
airflow_conf_set "api" "host" "${AIRFLOW_APISERVER_HOST}"
|
||||
airflow_conf_set "core" "execution_api_server_url" "http://${AIRFLOW_APISERVER_HOST}:${AIRFLOW_APISERVER_PORT_NUMBER}/execution/"
|
||||
fi
|
||||
airflow_conf_set "api" "host" "${AIRFLOW_APISERVER_HOST}"
|
||||
airflow_conf_set "core" "execution_api_server_url" "http://${AIRFLOW_APISERVER_HOST}:${AIRFLOW_APISERVER_PORT_NUMBER}/execution/"
|
||||
;;
|
||||
esac
|
||||
|
||||
if [[ $(airflow_major_version) -eq 2 ]]; then
|
||||
# Configure the web server
|
||||
airflow_conf_set "webserver" "web_server_port" "$AIRFLOW_APISERVER_PORT_NUMBER"
|
||||
else
|
||||
# Configure the api server
|
||||
airflow_conf_set "api" "port" "$AIRFLOW_APISERVER_PORT_NUMBER"
|
||||
fi
|
||||
# Configure the api server
|
||||
airflow_conf_set "api" "port" "$AIRFLOW_APISERVER_PORT_NUMBER"
|
||||
# Configure Airflow Hostname
|
||||
[[ -n "$AIRFLOW_HOSTNAME_CALLABLE" ]] && airflow_conf_set "core" "hostname_callable" "$AIRFLOW_HOSTNAME_CALLABLE"
|
||||
# Configure Airflow database
|
||||
@@ -315,14 +304,10 @@ airflow_generate_config() {
|
||||
|
||||
# Configure the web server secret key parameter
|
||||
secret_key_section="api"
|
||||
[[ $(airflow_major_version) -eq 2 ]] && secret_key_section="webserver"
|
||||
airflow_conf_set "${secret_key_section}" "secret_key" "${AIRFLOW_WEBSERVER_SECRET_KEY}"
|
||||
|
||||
[[ $(airflow_major_version) -ne 2 ]] && airflow_conf_set "api_auth" "jwt_secret" "$AIRFLOW_APISERVER_SECRET_KEY"
|
||||
airflow_conf_set "api_auth" "jwt_secret" "$AIRFLOW_APISERVER_SECRET_KEY"
|
||||
|
||||
local capacity_key="capacity"
|
||||
[[ $(airflow_major_version) -eq 2 ]] && capacity_key="default_capacity"
|
||||
|
||||
[[ "$AIRFLOW_COMPONENT_TYPE" = "triggerer" && -n "$AIRFLOW_TRIGGERER_DEFAULT_CAPACITY" ]] && airflow_conf_set "triggerer" "${capacity_key}" "$AIRFLOW_TRIGGERER_DEFAULT_CAPACITY"
|
||||
if [[ "$AIRFLOW_COMPONENT_TYPE" != "worker" ]]; then
|
||||
# Configure Airflow to load examples
|
||||
@@ -407,15 +392,11 @@ airflow_configure_host() {
|
||||
base_url="$(airflow_base_url "$host")"
|
||||
info "Configuring Airflow URL to ${base_url}"
|
||||
airflow_conf_set "webserver" "base_url" "${base_url}"
|
||||
if [[ $(airflow_major_version) -eq 3 ]]; then
|
||||
airflow_conf_set "api" "base_url" "${base_url}"
|
||||
fi
|
||||
airflow_conf_set "api" "base_url" "${base_url}"
|
||||
else
|
||||
info "Configuring Airflow URL to ${AIRFLOW_APISERVER_BASE_URL}"
|
||||
airflow_conf_set "webserver" "base_url" "$AIRFLOW_APISERVER_BASE_URL"
|
||||
if [[ $(airflow_major_version) -eq 3 ]]; then
|
||||
airflow_conf_set "api" "base_url" "$AIRFLOW_APISERVER_BASE_URL"
|
||||
fi
|
||||
airflow_conf_set "api" "base_url" "$AIRFLOW_APISERVER_BASE_URL"
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -480,10 +461,8 @@ airflow_configure_webserver_authentication() {
|
||||
# None
|
||||
#########################
|
||||
airflow_configure_webserver_hashing() {
|
||||
if [[ $(airflow_major_version) -eq 3 ]]; then
|
||||
info "Configuring Airflow webserver hashing method"
|
||||
airflow_webserver_conf_set "FAB_PASSWORD_HASH_METHOD" "pbkdf2:sha256" "yes"
|
||||
fi
|
||||
info "Configuring Airflow webserver hashing method"
|
||||
airflow_webserver_conf_set "FAB_PASSWORD_HASH_METHOD" "pbkdf2:sha256" "yes"
|
||||
}
|
||||
|
||||
########################
|
||||
@@ -662,7 +641,6 @@ airflow_create_admin_user() {
|
||||
airflow_create_pool() {
|
||||
if [[ -n "$AIRFLOW_POOL_NAME" ]] && [[ -n "$AIRFLOW_POOL_SIZE" ]] && [[ -n "$AIRFLOW_POOL_DESC" ]]; then
|
||||
local pool_cmd=("pools" "set")
|
||||
[[ $(airflow_major_version) -eq 2 ]] && pool_cmd=("pool" "-s")
|
||||
info "Creating Airflow pool"
|
||||
airflow_execute "${pool_cmd[@]}" "$AIRFLOW_POOL_NAME" "$AIRFLOW_POOL_SIZE" "$AIRFLOW_POOL_DESC"
|
||||
fi
|
||||
@@ -768,20 +746,6 @@ airflow_exporter_stop() {
|
||||
stop_service_using_pid "$AIRFLOW_EXPORTER_PID_FILE"
|
||||
}
|
||||
|
||||
########################
|
||||
# Get Airflow major version
|
||||
# Globals:
|
||||
# AIRFLOW_BASE_DIR
|
||||
# Arguments:
|
||||
# None
|
||||
# Returns:
|
||||
# airflow major version
|
||||
#########################
|
||||
airflow_major_version() {
|
||||
local -r raw_version="$("${AIRFLOW_BASE_DIR}/venv/bin/airflow" version | grep -v "WARNING\|DEBUG" 2>/dev/null)"
|
||||
get_sematic_version "$raw_version" 1
|
||||
}
|
||||
|
||||
########################
|
||||
# Generate a secret key for Airflow
|
||||
# Arguments:
|
||||
@@ -804,10 +768,8 @@ airflow_update_secret_keys() {
|
||||
local -r webserver_key="$(airflow_generate_secret_key)"
|
||||
airflow_conf_set "webserver" "secret_key" "${webserver_key}"
|
||||
|
||||
if [[ $(airflow_major_version) -eq 3 ]]; then
|
||||
local -r apiserver_key="$(airflow_generate_secret_key)"
|
||||
airflow_conf_set "api_auth" "jwt_secret" "${apiserver_key}"
|
||||
fi
|
||||
local -r apiserver_key="$(airflow_generate_secret_key)"
|
||||
airflow_conf_set "api_auth" "jwt_secret" "${apiserver_key}"
|
||||
}
|
||||
|
||||
########################
|
||||
|
||||
Reference in New Issue
Block a user