Config:Nginx:Express

出自 Chan
前往: 導覽搜尋
server {
    listen 80;
    server_name express.app;
    root /var/www/express/;

    location / {
        proxy_pass http://localhost:3000;
        # proxy_set_header Host $host:3000;
        proxy_set_header Host $http_host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    }
}