From 426e3bdc678748af4160277b6bb96e3972a65ece Mon Sep 17 00:00:00 2001 From: Robert Coleman <154176+rjocoleman@users.noreply.github.com> Date: Wed, 15 Jan 2025 10:24:27 +1300 Subject: [PATCH] limit env variables used for envsubsut in dnsmasq --- root/init.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/root/init.sh b/root/init.sh index abd60da..61c49bb 100755 --- a/root/init.sh +++ b/root/init.sh @@ -14,7 +14,7 @@ mkdir -p \ [[ ! -f /config/nginx/nginx.conf ]] && cp /defaults/nginx.conf /config/nginx/nginx.conf [[ ! -f /config/nginx/site-confs/default ]] && - envsubst '${NGINX_PORT}' < /defaults/default > /config/nginx/site-confs/default + envsubst '${NGINX_PORT}' /config/nginx/site-confs/default # create dnsmasq config, and conditionally add DHCP proxy support if [[ ! -f /config/dnsmasq/dnsmasq.conf ]]; then @@ -28,7 +28,7 @@ if [[ ! -f /config/dnsmasq/dnsmasq.conf ]]; then CONTAINER_IP=$(hostname -i) export CONTAINER_IP fi - envsubst >/config/dnsmasq/dnsmasq.conf + envsubst '${DHCP_RANGE_START} ${CONTAINER_IP}' >/config/dnsmasq/dnsmasq.conf fi fi