I have a nginx server setup as a proxy to a node js app using this config
Quote:
upstream app_nodejs {
server 127.0.0.1:8080;
}
server {
listen 80 default;
server_name toto.example.com;
root /www/apps/myapp;
index index.html;
location / {
proxy_http_version 1.1;
proxy_set_header Connection "";
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://app_nodejs;
proxy_pass_header Accept;
proxy_pass_header Server;
proxy_redirect off;
}
}
|
The problem I have is that I don't receive a valid HTTP Header from nginx. the Status-Line is missing and the Server line is missing.
When a curl -I the backend upstream server app_nodejs, I receive a correct header.
Any idea why?