Issue with spdy and proxy_pass

p.heppler nginx-forum at nginx.us
Tue Feb 18 14:15:25 UTC 2014


Hello,
I compiled nginx 1.5.10 on Centos 6.5 and try to use it as frontend for
Tomcat.
If I use pure SSL everything works fine. But as soon as I enable SPDY, I
only get a blank page.
And Content-Length Header is 0, but HTTP status code is 200.
But, the blank page only affects request which are handled by Tomcat. Static
files, served by nginx, work with SPDY.

Here my vhost conf:

# Redirect everything to ssl
server {
        listen      192.168.89.175:80;
        server_name example.org www.example.org;
        return 301   https://www.example.org$request_uri;
        }
# Redirect to www
server {
        listen      192.168.89.175:443 ssl spdy;
        server_name example.org
        return 301   https://www.example.org$request_uri;
        }
server {
        listen      192.168.89.175:443 ssl spdy;
        server_name www.example.org;
        ssl on;
        ssl_certificate /usr/share/nginx/ssl/example.org.crt;
        ssl_certificate_key /usr/share/nginx/ssl/example.org.key;

        ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
        ssl_prefer_server_ciphers on;
        ssl_ciphers "EECDH+AESGCM EDH+AESGCM EECDH -RC4 EDH -CAMELLIA -SEED
!aNULL !eNULL !LOW !3DES !MD5 !EXP !PSK !SRP !DSS !kEDH";
        ssl_session_cache  builtin:1000  shared:SSL:10m;

        root /usr/share/nginx/html/example.org;

        location / {
        try_files $uri $uri/ /index.cfm?q=$uri&$args;

        }
# Proxy CFML to Tomcat/Railo
	location ~ \.(cfm|cfml|cfc|jsp|cfr)(.*)$ {
    	proxy_pass http://127.0.0.1:8888;
    	proxy_pass_request_headers on;
   	proxy_redirect default;
   	proxy_set_header Host $host;
    	proxy_read_timeout 900;
    	proxy_set_header X-Forwarded-Host $host;
    	proxy_set_header X-Forwarded-Server $host;
    	proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    	proxy_set_header X-Real-IP $remote_addr;
    	}

     }

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,247692,247692#msg-247692



More information about the nginx mailing list