mirror of
https://github.com/mashirozx/docker-php-nginx.git
synced 2024-11-26 08:48:14 +08:00
10 lines
365 B
Docker
10 lines
365 B
Docker
FROM nginx:1.9
|
|
|
|
COPY nginx.conf /etc/nginx/conf.d/app.conf
|
|
|
|
CMD /bin/bash -c envsubst < /etc/nginx/conf.d/app.conf.template > /etc/nginx/conf.d/app.conf && nginx -g 'daemon off;'
|
|
|
|
CMD sed -i 's/UPSTREAM_HOST/'"$UPSTREAM_HOST"'/g' /etc/nginx/conf.d/app.conf \
|
|
&& sed -i 's/UPSTREAM_PORT/'"$UPSTREAM_PORT"'/g' /etc/nginx/conf.d/app.conf \
|
|
&& nginx -g 'daemon off;'
|