This commit is contained in:
Juan Pablo Vial
2024-10-31 16:31:42 -03:00
parent d649e03684
commit 3d5799ae58
2 changed files with 27 additions and 0 deletions

View File

@ -7,6 +7,7 @@ services:
restart: unless-stopped restart: unless-stopped
ports: ports:
- "${APP_PORT}:80" - "${APP_PORT}:80"
- "${APP_SSL_PORT}:443"
volumes: volumes:
- ${APP_PATH:-.}/:/code - ${APP_PATH:-.}/:/code
- ./nginx.conf:/etc/nginx/conf.d/default.conf - ./nginx.conf:/etc/nginx/conf.d/default.conf

View File

@ -21,3 +21,29 @@ server {
fastcgi_pass web:9000; fastcgi_pass web:9000;
} }
} }
server {
listen 443;
listen [::]:443;
index index.php;
error_log /logs/error.log;
access_log /logs/access.log;
root /code/public;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri $uri/ =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param SCRIPT_NAME $fastcgi_script_name;
fastcgi_index index.php;
fastcgi_read_timeout 3600;
fastcgi_pass web:9000;
}
}