Docker web-server image to serve static files and redirect router PHP file to PHP-FPM.
/code/public. If not change APP_WORKDIRAPP_DOMAINindex.php. If not change PHP_APP_FILEfpm:9000. If not change PHP_HOST and PHP_PORTREMOTE_ADDR_PARAM - for direct connection set "remote_addr"SEND_TIMEOUT and PHP_TIMEOUT./var/log/nginx/. If not change LOG (2 - access and error, 1 - only error, 0 - no logs)APP_ENVHTTPSSSLVERBOSE="0"Files you can mount:
/opt/nginx/fix.sh: if exists it will be executed after config before nginx start. Good place for replacements
sed -i 's/incorrect/correct/' /etc/nginx/nginx.conf/opt/nginx/locations.conf: if exists it is appended to server locationsmake build
docker:
docker run --rm -it --name nginx -p 80:80 -v /path/to/your/app/:/code/ gupalo/nginx
docker-compose.yaml:
nginx:
image: 'gupalo/nginx'
ports: ['0.0.0.0:80:80']
depends_on: ['fpm']
volumes_from: ['fpm:ro']
#env_file: ['./env.conf']
restart: 'always'
networks: ['default']
Content type
Image
Digest
sha256:dac5d69f4…
Size
54.1 MB
Last updated
about 4 years ago
docker pull gupalo/nginx