server { listen 80; server_name cocottes; return 302 https://cocottes; } server { listen 443 ssl; server_name cocottes; root /var/www/cocottes; location / { } index index.php; # managed by Certbot ssl_certificate /etc/letsencrypt/live/cocottes/cert.pem; # managed by Certbot ssl_certificate_key /etc/letsencrypt/live/cocottes/privkey.pem; # managed by Certbot location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/run/php/www.sock; } }