HAProxy community

Reverse Proxy to internal frappe server: failing login

Hi all,

I am using HAProxy as my reverse proxy on an OPNSense firewall. In the backend currently I have two servers: jitsi and frappe/ERPNext

I am running a dyndns with subdomains of my domain at strato and SSL via Let’s encrypt for the two domains.

Accessing the Servers via the public dynDNS domains works fine with the SSL certificates. For Jitis I also configured some port forwarding in the firewall.

Jitsi runs fine.

Frappe/ERPNext allows to access the front page and visit any non-password protected sites. However, when I try to login Frappe fails to perform the login.

The error-log can be seen herer:

I know that this may be a frappe specific problem. However, I hope there may be some simple option or header in HAProxy that I may set to support the login to frappe.

Any help is appreciated!

Thanks
DoCa

I further investigated the issue, since I have the same with a django based app “passit”.
For my frappe/ERPNext I could solve the login problem by applying to the backend:

I now found a solution to make frappe user authenticatio work behind a reverse proxy with basic auth:

http-request set-header Host frappe.home.local
http-request del-header Authorization

Cheers!