Created
February 17, 2021 15:37
-
-
Save ferhatbostanci/54b9ef2502ba011eb79103ca0a96131d to your computer and use it in GitHub Desktop.
Mailcatcher with Nginx Reverse Proxy
This file contains hidden or 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
server { | |
location /mailcatcher { | |
proxy_pass http://127.0.0.1:1080/; | |
proxy_http_version 1.1; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_set_header Connection "upgrade"; | |
proxy_read_timeout 1d; | |
sub_filter 'src="/' 'src="/mailcatcher/'; | |
sub_filter 'href="/' 'href="/mailcatcher/'; | |
sub_filter 'url(/' 'url(/mailcatcher/'; | |
sub_filter '"/messages' '"/mailcatcher/messages'; | |
sub_filter_types text/css application/javascript application/json; | |
sub_filter_once off; | |
} | |
} |
thx ๐
Thank you! ๐
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks a lot!