Skip to content

Commit e1eebaf

Browse files
authored
fix nginx start error (#35)
1 parent da6ef55 commit e1eebaf

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

docker_openresty/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ RUN set -eux \
1616
&& useradd nginx -G www-data \
1717
&& mkdir -pv /var/cache/nginx /var/log/nginx \
1818
&& chown -R nginx:www-data /var/cache/nginx /var/log/nginx \
19+
&& chmod +x /opt/utils/*.sh \
1920
&& source /opt/utils/script-setup.sh && setup_lua_base && setup_lua_rocks \
2021
&& source /opt/utils/script-setup-openresty.sh && setup_openresty \
2122
&& source /opt/utils/script-setup-acme.sh && setup_acme \

docker_openresty/work/entrypoint/docker-entrypoint.d/99-localize.sh

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,9 @@
33

44
set -eu
55

6-
PROFILE_LOCALIZE=${PROFILE_LOCALIZE:-"default"} ;
7-
echo "PROFILE_LOCALIZE=${PROFILE_LOCALIZE}" ;
8-
96
# Check if the environment variable PROFILE_LOCALIZE is set and not empty
10-
if [ -n "$PROFILE_LOCALIZE" ]; then
11-
/bin/sh /opt/utils/script-localize.sh ;
12-
else
7+
if [ -z "${PROFILE_LOCALIZE+x}" ]; then
138
echo "No action taken as PROFILE_LOCALIZE is not set or is empty." ;
9+
else
10+
/bin/sh /opt/utils/script-localize.sh ;
1411
fi

0 commit comments

Comments
 (0)