server { listen 80; server_name {{ snipeit_nginx_servername }}; return 301 https://$server_name$request_uri; } server { listen 443 ssl; server_name {{ snipeit_nginx_servername }}; ssl_certificate {{ snipeit_ssl_crt }}; ssl_certificate_key {{ snipeit_ssl_key }}; ssl_session_timeout 5m; ssl_session_cache builtin:1000 shared:SSL:10m; root {{ snipeit_install_path }}/public/; index index.php index.html index.htm; location / { try_files $uri $uri/ /index.php$is_args$args; } location ~ \.php$ { try_files $uri $uri/ =404; fastcgi_pass unix:/var/run/php-fpm/www.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }