Welcome! Log In Create A New Profile

Advanced

Re: HTTP/2 and HTTPS

Richard Stanway
March 14, 2016 07:10PM
You probably need to specify the IP on the listen directive if you want
different configurations of listening ports on different IPs.

On Mon, Mar 14, 2016 at 11:43 PM, Roswebnet <nginx-forum@forum.nginx.org>
wrote:

> Hi everyone,
>
> I have strange issue with nginx 1.9.12. I have 3 IP addresses as a server
> name that are alias IPs on a single Ubuntu server 15.10. Each servername
> related to specific protocol:
>
> http:
>
> server {
> listen 80;
> server_name 192.168.1.161;
>
> #charset koi8-r;
> #access_log /var/log/nginx/log/host.access.log main;
>
> location / {
> root /usr/share/nginx/static;
> index index.html;
> }
>
> #error_page 404 /404.html;
>
> # redirect server error pages to the static page /50x.html
> #
> error_page 500 502 503 504 /50x.html;
> location = /50x.html {
> root /usr/share/nginx/html;
> }
> }
>
> https:
>
> server {
> listen 443 ssl;
> server_name 192.168.1.162;
>
> #charset koi8-r;
> #access_log /var/log/nginx/log/host.access.log main;
>
> root /usr/share/nginx/static;
> index index.html index.htm;
>
> ssl_certificate /etc/nginx/tls/certificate.crt;
> ssl_certificate_key /etc/nginx/tls/privatekey.key;
>
>
> ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
> ssl_ciphers HIGH+kEECDH+AESGCM:HIGH+kEECDH:HIGH+kEDH:HIGH:!aNULL;
>
> location / {
> try_files $uri $uri/ =404;
> }
>
> #error_page 404 /404.html;
>
> # redirect server error pages to the static page /50x.html
> #
> error_page 500 502 503 504 /50x.html;
> location = /50x.html {
> root /usr/share/nginx/html;
> }
> }
>
> http2:
>
> server {
> listen 443 ssl http2;
> server_name 192.168.1.163;
>
> #charset koi8-r;
> #access_log /var/log/nginx/log/host.access.log main;
>
> ssl_certificate /etc/nginx/tls/certificate.crt;
> ssl_certificate_key /etc/nginx/tls/privatekey.key;
>
> location / {
> root /usr/share/nginx/static;
> index index.html index.htm;
> }
>
> #error_page 404 /404.html;
>
> # redirect server error pages to the static page /50x.html
> #
> error_page 500 502 503 504 /50x.html;
> location = /50x.html {
> root /usr/share/nginx/html;
> }
> }
>
>
> As you see for those servers content is the same, and it is served well.
> However, if I use webconsole of Firefox I am getting that https site is a
> http2 site and http2 site is http2. The same situation is in Internet
> explorer.
>
> What I am doing wrong?
>
> Thank you.
>
> Posted at Nginx Forum:
> https://forum.nginx.org/read.php?2,265326,265326#msg-265326
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

HTTP/2 and HTTPS

Roswebnet March 14, 2016 06:43PM

Re: HTTP/2 and HTTPS

Richard Stanway March 14, 2016 07:10PM

Re: HTTP/2 and HTTPS

Roswebnet March 14, 2016 07:39PM

Re: HTTP/2 and HTTPS

Sven Kirschbaum March 14, 2016 08:38PM

Re: HTTP/2 and HTTPS

Roswebnet March 15, 2016 10:23AM

Re: HTTP/2 and HTTPS

Valentin V. Bartenev March 15, 2016 11:16AM

Re: HTTP/2 and HTTPS

Roswebnet March 15, 2016 11:54AM

Re: HTTP/2 and HTTPS

Valentin V. Bartenev March 15, 2016 12:46PM

Re: HTTP/2 and HTTPS

Roswebnet March 15, 2016 01:33PM

Re: HTTP/2 and HTTPS

Valentin V. Bartenev March 15, 2016 02:34PM

Re: HTTP/2 and HTTPS

GreenGecko March 16, 2016 02:02AM

Re: HTTP/2 and HTTPS

Roswebnet March 16, 2016 07:10AM

Re: HTTP/2 and HTTPS

Roswebnet March 16, 2016 07:12AM

Re: HTTP/2 and HTTPS

itpp2012 March 16, 2016 08:24AM

Re: HTTP/2 and HTTPS

Roswebnet March 16, 2016 08:30AM

Re: HTTP/2 and HTTPS

B.R. March 15, 2016 04:04AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 256
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready