From 7da42b882aa67c975f7209138ea3930230fd431d Mon Sep 17 00:00:00 2001 From: TrueGameover Date: Wed, 11 Sep 2024 13:26:46 +0700 Subject: [PATCH] [bitnami/nginx] stream server blocks Signed-off-by: TrueGameover --- .../1.27/debian-12/rootfs/opt/bitnami/nginx/conf/nginx.conf | 4 ++++ .../1.27/debian-12/rootfs/opt/bitnami/scripts/nginx-env.sh | 1 + .../debian-12/rootfs/opt/bitnami/scripts/nginx/postunpack.sh | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/nginx/conf/nginx.conf b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/nginx/conf/nginx.conf index 9833b1cfd0437..8c35872faf87a 100644 --- a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/nginx/conf/nginx.conf +++ b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/nginx/conf/nginx.conf @@ -58,3 +58,7 @@ http { } } } + +stream { + include "/opt/bitnami/nginx/conf/stream_server_blocks/*.conf"; +} \ No newline at end of file diff --git a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx-env.sh b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx-env.sh index 4e98ba15350be..cfed2e1a92ec4 100644 --- a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx-env.sh +++ b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx-env.sh @@ -54,6 +54,7 @@ export NGINX_HTDOCS_DIR="${NGINX_BASE_DIR}/html" export NGINX_TMP_DIR="${NGINX_BASE_DIR}/tmp" export NGINX_LOGS_DIR="${NGINX_BASE_DIR}/logs" export NGINX_SERVER_BLOCKS_DIR="${NGINX_CONF_DIR}/server_blocks" +export NGINX_STREAM_SERVER_BLOCKS_DIR="${NGINX_CONF_DIR}/stream_server_blocks" export NGINX_INITSCRIPTS_DIR="/docker-entrypoint-initdb.d" export NGINX_CONF_FILE="${NGINX_CONF_DIR}/nginx.conf" export NGINX_PID_FILE="${NGINX_TMP_DIR}/nginx.pid" diff --git a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx/postunpack.sh b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx/postunpack.sh index 8a260a732906a..26b18da3c3b68 100755 --- a/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx/postunpack.sh +++ b/bitnami/nginx/1.27/debian-12/rootfs/opt/bitnami/scripts/nginx/postunpack.sh @@ -39,7 +39,7 @@ rm -rf "${BITNAMI_ROOT_DIR}/certs" "${BITNAMI_ROOT_DIR}/server_blocks" # Ensure non-root user has write permissions on a set of directories chmod g+w "$NGINX_BASE_DIR" -for dir in "$NGINX_VOLUME_DIR" "$NGINX_CONF_DIR" "$NGINX_INITSCRIPTS_DIR" "$NGINX_SERVER_BLOCKS_DIR" "${NGINX_CONF_DIR}/bitnami" "${NGINX_CONF_DIR}/bitnami/certs" "$NGINX_LOGS_DIR" "$NGINX_TMP_DIR" "$NGINX_DEFAULT_CONF_DIR"; do +for dir in "$NGINX_VOLUME_DIR" "$NGINX_CONF_DIR" "$NGINX_INITSCRIPTS_DIR" "$NGINX_SERVER_BLOCKS_DIR" "$NGINX_STREAM_SERVER_BLOCKS_DIR" "${NGINX_CONF_DIR}/bitnami" "${NGINX_CONF_DIR}/bitnami/certs" "$NGINX_LOGS_DIR" "$NGINX_TMP_DIR" "$NGINX_DEFAULT_CONF_DIR"; do ensure_dir_exists "$dir" chmod -R g+rwX "$dir" done