Skip to content

Instantly share code, notes, and snippets.

@praveenc
Last active April 23, 2018 18:33
Show Gist options
  • Save praveenc/03893da76bc7d341f9e299d4678524fb to your computer and use it in GitHub Desktop.
Save praveenc/03893da76bc7d341f9e299d4678524fb to your computer and use it in GitHub Desktop.
configure nginx as a reverse proxy to forward requests to ASP.NET Core app
server {
listen 443 ssl;
ssl_certificate /etc/nginx/ssl/nginx.crt;
ssl_certificate_key /etc/nginx/ssl/nginx.key;
location / {
proxy_pass http://localhost:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection keep-alive;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
@praveenc
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment