server { listen 443 quic; listen 443 ssl; http2 on; http3 on; ssl_protocols TLSv1.3 TLSv1.2; ssl_early_data on; add_header Alt-Svc 'h3=":$server_port"; ma=86400'; server_name img.gruszczynski.eu.org; set $base /var/www/img.gruszczynski.eu.org; root $base/img; ssl_certificate /etc/letsencrypt/live/img.gruszczynski.eu.org/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/img.gruszczynski.eu.org/privkey.pem; ssl_trusted_certificate /etc/letsencrypt/live/img.gruszczynski.eu.org/chain.pem; # ssl cfg include config/ssl_cfg.conf; # security include config/security.conf; # restrict methods if ($request_method !~ ^(GET)$) { return '405'; } # logging access_log /var/log/angie/img.gruszczynski.eu.org.access.log; error_log /var/log/angie/img.gruszczynski.eu.org.error.log warn; include config/general.conf; # letsencrypt include config/letsencrypt.conf; } # HTTP redirect server { listen 80; server_name img.gruszczynski.eu.org; add_header Alt-Svc 'h3=":443"; ma=86400'; set $base /var/www/img.gruszczynski.eu.org; root $base/img; include config/letsencrypt.conf; # logging access_log /var/log/angie/img.gruszczynski.eu.org.access.log; error_log /var/log/angie/img.gruszczynski.eu.org.error.log warn; # restrict methods if ($request_method !~ ^(GET)$) { return '405'; } location / { return 301 https://img.gruszczynski.eu.org$request_uri; } }