Allow to run under subpath with reverse proxy
riaanp78 opened this issue · 6 comments
Love this project! trying to setup a reverse proxy using sub directory. Was wondering if mailwhale supports it?
This is the config I am using:
location /mailwhale/ {
proxy_pass http://127.0.0.1:3005;
proxy_set_header Host iot.rplab.xyz;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
Any hints?
Looks about right. What specific errors are you getting with that config?
I think I'll have to implement a few tweaks to support being reverse-proxied under a subpath. Probably similar to this:
https://github.com/muety/wakapi/blob/master/views/head.tpl.html
https://github.com/muety/wakapi/blob/master/routes/routes.go#L47
https://github.com/muety/wakapi/blob/master/config/config.go#L124
I'll keep you posted.
Thank you! Not strictly required, but great if it could.
Added support for running behind reverse proxy under a subpath ✔️ Check README for instructions.
Thank you so much. Will check it out