Last active
August 30, 2023 19:10
-
-
Save sj26/9885403 to your computer and use it in GitHub Desktop.
Proxy mailcatcher with nginx including WebSockets
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
daemon off; | |
error_log stderr; | |
events { | |
worker_connections 1024; | |
} | |
http { | |
# As suggested in http://nginx.org/en/docs/http/websocket.html | |
map $http_upgrade $connection_upgrade { | |
default upgrade; | |
"" close; | |
} | |
server { | |
listen 127.0.0.1:8080; | |
location / { | |
proxy_pass http://127.0.0.1:1080; | |
proxy_http_version 1.1; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_set_header Connection $connection_upgrade; | |
} | |
} | |
} |
Wonderful
No Dice
The message you were looking for does not exist, or doesn't have content of this type.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This worked nicely, thanks!