server { root /var/www/www.tangohub.app; index index.html index.php index.htm index.nginx-debian.html; server_name www.tangohub.app tangohub.app; client_max_body_size 200M; location / { #try_files $uri $uri/ =404; try_files $uri $uri/ /index.php?$args; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/run/php/php8.0-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; fastcgi_connect_timeout 300s; fastcgi_read_timeout 300s; fastcgi_send_timeout 300s; } location ~* \.(eot|otf|ttf|woff|woff2)$ { add_header Access-Control-Allow-Origin *; } listen [::]:443 ssl ipv6only=on; # managed by Certbot listen 443 ssl; # managed by Certbot ssl_certificate /etc/letsencrypt/live/tangohub.app/fullchain.pem; # managed by Certbot ssl_certificate_key /etc/letsencrypt/live/tangohub.app/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 = www.tangohub.app) { return 301 https://$host$request_uri; } # managed by Certbot if ($host = tangohub.app) { return 301 https://$host$request_uri; } # managed by Certbot listen 80; listen [::]:80; server_name www.tangohub.app tangohub.app; return 404; # managed by Certbot }