Skip to content

Commit

Permalink
fix(nginx): migrate deprecated config
Browse files Browse the repository at this point in the history
Reference:
Changes with nginx 1.25.1 (13 Jun 2023)
Feature: the "http2" directive, which enables HTTP/2 on a per-server basis; the "http2" parameter of the "listen" directive is now deprecated.
  • Loading branch information
Rotzbua committed Aug 15, 2023
1 parent fb03802 commit bee8909
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 19 deletions.
5 changes: 3 additions & 2 deletions www/conf/sites-available/00-default.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ server {
return 444; # see https://httpstatuses.com/444
}
server {
listen 443 ssl http2 default_server;
listen [::]:443 ipv6only=on ssl http2 default_server;
listen 443 ssl default_server;
listen [::]:443 ipv6only=on ssl default_server;
http2 on;
server_name _;

ssl_certificate ${CERT_PATH}desec.${DESECSTACK_DOMAIN}.cer;
Expand Down
10 changes: 6 additions & 4 deletions www/conf/sites-available/05-dedyn.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ server {
}
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}dedyn.${DESECSTACK_DOMAIN}.cer;
Expand All @@ -35,8 +36,9 @@ server {
}
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name www.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}www.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand Down
11 changes: 7 additions & 4 deletions www/conf/sites-available/10-dedyn-checkip.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ server {
}
}
server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name checkipv4.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}checkipv4.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand Down Expand Up @@ -54,7 +55,8 @@ server {
}
}
server {
listen [::]:443 ssl http2;
listen [::]:443 ssl;
http2 on;
server_name checkipv6.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}checkipv6.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand Down Expand Up @@ -85,8 +87,9 @@ server {
}
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name checkip.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}checkip.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand Down
8 changes: 5 additions & 3 deletions www/conf/sites-available/15-dedyn-update.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,9 @@ server {
# Handle update requests with SSL
######
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name update.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}update.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand All @@ -55,7 +56,8 @@ server {
}
}
server {
listen [::]:443 ssl http2;
listen [::]:443 ssl;
http2 on;
server_name update6.dedyn.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}update6.dedyn.${DESECSTACK_DOMAIN}.cer;
Expand Down
10 changes: 6 additions & 4 deletions www/conf/sites-available/85-redirects.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@ server {
# Strip www. from HTTPS requests on www.desec.*
######
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name www.desec.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}www.desec.${DESECSTACK_DOMAIN}.cer;
Expand All @@ -38,8 +39,9 @@ server {
# For the "get" subdomain, we redirect to the main page for now
######
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name get.desec.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}get.desec.${DESECSTACK_DOMAIN}.cer;
Expand Down
5 changes: 3 additions & 2 deletions www/conf/sites-available/90-desec.conf.var
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
# The website server
######
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name desec.$DESECSTACK_DOMAIN;

ssl_certificate ${CERT_PATH}desec.${DESECSTACK_DOMAIN}.cer;
Expand Down

0 comments on commit bee8909

Please sign in to comment.