nginx.conf

Created Diff never expires
1 removal
Lines
Total
Removed
Words
Total
Removed
To continue using this feature, upgrade to
Diffchecker logo
Diffchecker Pro
16 lines
25 additions
Lines
Total
Added
Words
Total
Added
To continue using this feature, upgrade to
Diffchecker logo
Diffchecker Pro
40 lines
server {
server {
listen 80 default_server;
listen 80 default_server;


server_name [domain-name] www.[domain-name];
server_tokens off;

location /.well-known/acme-challenge/ {
root /var/www/certbot;
}

location / {
return 301 https://[domain-name]$request_uri;
}
}

server {
listen 443 default_server ssl http2;
listen [::]:443 ssl http2;

server_name [domain-name];

ssl_certificate /etc/nginx/ssl/live/[domain-name]/fullchain.pem;
ssl_certificate_key /etc/nginx/ssl/live/[domain-name]/privkey.pem;

location / {
proxy_pass http://[domain-name];
}

index index.php index.html index.htm;
index index.php index.html index.htm;


location ~ [^/]\.php(/|$) {
location ~ [^/]\.php(/|$) {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_index index.php;
fastcgi_index index.php;
fastcgi_pass php:9000;
fastcgi_pass php:9000;
include fastcgi_params;
include fastcgi_params;
fastcgi_read_timeout 1200s;
fastcgi_read_timeout 1200s;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
}
}