Skip to content

Instantly share code, notes, and snippets.

@kastaneda
Created June 12, 2018 16:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kastaneda/eb0dca61f0c6b4ef0b6b6792f5286e89 to your computer and use it in GitHub Desktop.
Save kastaneda/eb0dca61f0c6b4ef0b6b6792f5286e89 to your computer and use it in GitHub Desktop.
version: '3'
services:
php:
image: php:7-fpm
volumes:
- ./app:/app:rw
- ./php-misc.ini:/usr/local/etc/php/conf.d/docker-php.ini:ro
web:
image: nginx:latest
ports:
- '8080:80'
volumes:
- ./app:/app:rw
- ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
server {
server_name localhost;
root /app/public;
location / {
try_files $uri /index.php$is_args$args;
}
location ~ \.php$ {
fastcgi_pass php:9000;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
fastcgi_param DOCUMENT_ROOT $realpath_root;
}
}
log_errors=1
date.timezone=Europe/Kiev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment