Skip to content

Instantly share code, notes, and snippets.

@davext
Created May 28, 2021 18:07
Show Gist options
  • Save davext/2653de2b07503eafe6f0d52b59ba64fa to your computer and use it in GitHub Desktop.
Save davext/2653de2b07503eafe6f0d52b59ba64fa to your computer and use it in GitHub Desktop.
NGINX Reverse proxy for PM2 and Node.js Apps
. . .
location / {
proxy_pass http://localhost:8080;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment