Skip to content

Commit

Permalink
The "listen ... http2" directive is deprecated, use the "http2" direc…
Browse files Browse the repository at this point in the history
…tive instead

The "http2" directive appeared in nginx 1.25.1.
  • Loading branch information
spaze committed Jul 29, 2023
1 parent 55b962b commit 8427da6
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 35 deletions.
6 changes: 4 additions & 2 deletions conf/nginx/dev-michal-spacek.cz.conf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name .michal-spacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michal-spacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.cz.conf;
Expand All @@ -40,7 +41,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name .michal-spacek.com.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michal-spacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.com.conf;
Expand Down
27 changes: 18 additions & 9 deletions conf/nginx/dev-michalspacek.cz.conf
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name .michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.cz.conf;
Expand All @@ -105,7 +106,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name .michalspacek.com.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.com.conf;
Expand All @@ -115,7 +117,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name admin.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-admin.michalspacek.cz.conf;
Expand All @@ -125,7 +128,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name api.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-api.michalspacek.cz.conf;
Expand All @@ -135,7 +139,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name heartbleed.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-heartbleed.michalspacek.cz.conf;
Expand All @@ -145,7 +150,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name mta-sts.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-mta-sts.michalspacek.cz.conf;
Expand All @@ -155,7 +161,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name pulse.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-pulse.michalspacek.cz.conf;
Expand All @@ -165,7 +172,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name upc.michalspacek.cz.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-upcwifikeys.com.conf;
Expand All @@ -174,7 +182,8 @@ server {
}

server {
listen 443 ssl http2;
listen 443 ssl;
http2 on;
server_name .upcwifikeys.com.test;
include /srv/www/michalspacek.cz/conf/nginx/dev-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-upcwifikeys.com.conf;
Expand Down
10 changes: 6 additions & 4 deletions conf/nginx/prod-michal-spacek.cz.conf
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name .michal-spacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michal-spacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.cz.conf;
Expand All @@ -45,8 +46,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name .michal-spacek.com;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michal-spacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.com.conf;
Expand Down
50 changes: 30 additions & 20 deletions conf/nginx/prod-michalspacek.cz.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ server {
}

server {
listen 443 ssl http2 default_server;
listen [::]:443 ssl http2 default_server;
listen 443 ssl default_server;
listen [::]:443 ssl default_server;
http2 on;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-headers-redir&notfound.conf;
return 301 https://www.michalspacek.cz$request_uri;
Expand Down Expand Up @@ -122,8 +123,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name .michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.cz.conf;
Expand All @@ -133,8 +135,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name .michalspacek.com;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-michalspacek.com.conf;
Expand All @@ -144,8 +147,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name admin.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-admin.michalspacek.cz.conf;
Expand All @@ -155,8 +159,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name api.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-api.michalspacek.cz.conf;
Expand All @@ -166,8 +171,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name heartbleed.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-heartbleed.michalspacek.cz.conf;
Expand All @@ -177,8 +183,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name mta-sts.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/common-https.conf;
ssl_certificate /etc/nginx/certs/mta-sts.michalspacek.cz.fullchain.pem;
Expand All @@ -190,8 +197,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name pulse.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-pulse.michalspacek.cz.conf;
Expand All @@ -201,8 +209,9 @@ server {
}

server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name upc.michalspacek.cz;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-michalspacek.cz.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-upcwifikeys.com.conf;
Expand All @@ -212,8 +221,9 @@ server {


server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
listen 443 ssl;
listen [::]:443 ssl;
http2 on;
server_name .upcwifikeys.com;
include /srv/www/michalspacek.cz/conf/nginx/prod-https-upcwifikeys.com.conf;
include /srv/www/michalspacek.cz/conf/nginx/common-upcwifikeys.com.conf;
Expand Down

0 comments on commit 8427da6

Please sign in to comment.