server { listen 80 default_server; listen [::]:80 default_server; root /var/www/web/public; server_name kerberos.rpi; index index.php index.html index.htm; location / { autoindex on; try_files $uri $uri/ /index.php?$query_string; } location ~ \.php$ { fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } } server { root /var/www/web/public; server_name logan.zefiroengenharia.com; # managed by Certbot index index.php index.html index.htm; location / { autoindex on; try_files $uri $uri/ /index.php?$query_string; } location ~ \.php$ { fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } listen [::]:443 ssl ipv6only=on; # managed by Certbot listen 443 ssl; # managed by Certbot ssl_certificate /etc/letsencrypt/live/logan.zefiroengenharia.com/fullchain.pem; # managed by Certbot ssl_certificate_key /etc/letsencrypt/live/logan.zefiroengenharia.com/privkey.pem; # managed by Certbot include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot } server { if ($host = logan.zefiroengenharia.com) { return 301 https://$host$request_uri; } # managed by Certbot listen 80 ; listen [::]:80 ; server_name logan.zefiroengenharia.com; return 404; # managed by Certbot }