etc-configs/nginx/sites-available/4get.zzls.xyz.conf

71 lines
1.3 KiB
Plaintext

# CLEARNET
server {
server_name 4get.zzls.xyz;
include configs/general.conf;
root /var/www/4get;
#index index.php;
location @php {
try_files $uri.php $uri/index.php =404;
#fastcgi_param PHP_VALUE open_basedir=$document_root;
fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
fastcgi_index index.php;
include fastcgi.conf;
fastcgi_intercept_errors on;
}
location / {
try_files $uri @php;
}
location ~* ^(.*)\.php$ {
return 301 $1;
}
# QUIC
add_header Alt-Svc 'h3=":443";ma=86400';
# CSP + Security Headers
include configs/security.conf;
listen 443 ssl;
listen 443 quic;
http2 on;
include configs/ssl.conf;
}
server {
listen 80;
server_name 4get.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion;
root /var/www/4get;
location @php {
try_files $uri.php $uri/index.php =404;
fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
fastcgi_index index.php;
include fastcgi.conf;
fastcgi_intercept_errors on;
}
location / {
try_files $uri @php;
}
location ~* ^(.*)\.php$ {
return 301 $1;
}
}
server {
if ($host = 4get.zzls.xyz) {
return 301 https://$host$request_uri;
}
listen 80;
server_name 4get.zzls.xyz;
}