OPNsense Forum

English Forums => Web Proxy Filtering and Caching => Topic started by: cwt on May 01, 2021, 11:58:15 AM

Title: Access docker container behind HAProxy -> 503
Post by: cwt on May 01, 2021, 11:58:15 AM
Howdy!

I'm running the current HAProxy plugin along with the LE plugin, SSL offloading, etc. Everything works (nextcloud VMs, Synologys, etc.) except access to docker containers.

I'm trying to access a docker container (Bitwarden_RS) but only receive a 503 from HAProxy when trying to access it via HAProxy (external access). It's IP is definded both as a real server and in the backend settings. I can access it internally by browser with no problems (simply entering the IP of the docker container).

I usually set "host matches" as rules/conditions but this doesn't work.

Are there any special options in rules and conditions to access docker containers?

The container is started with ports 80:80 and 3012:3012 (web sockets enabled). I already tried port 3012 in HAProxy but the result is the same.

Thx and cheers  ;)
Title: Re: Access docker container behind HAProxy -> 503
Post by: cwt on May 20, 2021, 06:57:26 PM
*facepalm*

Ok, figured it out. Being lazy I duplicated the settings from an already existing ,,real server" and simply forgot to untick the option ,,SSL" which was activated  :-[ :P   :o

Errm...
Title: Re: Access docker container behind HAProxy -> 503
Post by: ckocank on April 08, 2023, 06:45:59 PM
thank you I'm having the exact same problem :)