Nginx upstream https not proxing other pages(?)

romkaltu nginx-forum at
Thu Jun 23 09:26:21 UTC 2016

Having odd situation, even don't know how to search in google, how to
describe it...Anyway I'm using Nginx and proxy'ing https traffic to upstream
server. Everything is fine with http (with others domains) but can't get it
to work with https...

Here is my nginx config

upstream umarket { server; }

# Upstream
server {
    listen 80;
    listen 443 ssl http2;

    error_log  /var/log/nginx/umarket.lt_error.log;

    add_header Strict-Transport-Security "max-age=31536000";

    ssl on;
    ssl_certificate_key         /etc/nginx/ssl/;
    ssl_session_cache           builtin:1000 shared:SSL:10m;
    ssl_protocols               TLSv1 TLSv1.1 TLSv1.2;
    ssl_ciphers HIGH:!aNULL:!eNULL:!EXPORT:!CAMELLIA:!DES:!MD5:!PSK:!RC4;
    ssl_prefer_server_ciphers   on;

    proxy_redirect              off;
    proxy_buffering             off;
    proxy_set_header            Host $host;
    proxy_set_header            X-Real-IP $remote_addr;
    proxy_set_header            X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header            X-Forwarded-Proto https;
    proxy_next_upstream         error timeout invalid_header http_500
http_502 http_503 http_504;
    proxy_ssl_session_reuse     off;
    proxy_cache_bypass          $http_secret_header;
    proxy_ignore_headers        Set-Cookie;
    proxy_ignore_headers        Cache-Control;

    location = / {

        proxy_pass  $scheme://umarket;



Here screenshot whats happening...

Posted at Nginx Forum:,267806,267806#msg-267806

More information about the nginx mailing list