Working docker-compose files for development

This commit is contained in:
Nabeel Shahzad
2019-05-10 18:40:07 -05:00
parent 2b45b9fd70
commit 5f0db96fc4
8 changed files with 87 additions and 4 deletions

27
docker/nginx/default.conf Normal file
View File

@@ -0,0 +1,27 @@
server {
listen 80 default_server;
server_name phpvms.test;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
root /var/www/public;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass app:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
location ~ /\.ht {
deny all;
}
}

3
docker/php/Dockerfile Normal file
View File

@@ -0,0 +1,3 @@
FROM php:7.3-fpm
RUN docker-php-ext-install mysqli pdo openssl mbstring tokenizer curl json gmp

12
docker/php/www.conf Normal file
View File

@@ -0,0 +1,12 @@
[www]
user = www-data
group = www-data
listen = :9000
pm = dynamic
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3