Skip to content

Commit 4cd5bb8

Browse files
committed
Set default value in Dockerfile
1 parent 77f6f3a commit 4cd5bb8

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ RUN apk add --no-cache --update \
55
apache2-utils
66

77
ENV SERVER_NAME example.com
8+
ENV PORT 80
89
ENV WORKER_PROCESSES auto
910

1011
COPY files/run.sh /

files/run.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ htpasswd -bBc /etc/nginx/.htpasswd $BASIC_AUTH_USERNAME $BASIC_AUTH_PASSWORD
2121
sed \
2222
-e "s/##WORKER_PROCESSES##/$WORKER_PROCESSES/g" \
2323
-e "s/##SERVER_NAME##/$SERVER_NAME/g" \
24-
-e "s/##PORT##/${PORT:-80}/g" \
24+
-e "s/##PORT##/$PORT/g" \
2525
-e "s|##PROXY_PASS##|$PROXY_PASS|g" \
2626
nginx.conf.tmpl > /etc/nginx/nginx.conf
2727

0 commit comments

Comments
 (0)