0

I need to load balancing one of our customers application portal. The flow works as follow:

  1. The enduser reach the portal through the URL example.net:3000/login page;

  2. The enduser will choose one of four possible portal tenants each one with a dedicated custom port (example ports :3012, :3013, :3014, :3015);

  3. Once the user managed to login the application automatically performs a path rewrite first into example.net:3000/auth/login (and manage the login) then redirect with a 302 status code into the path example.net:3000/redirect/, finally change the dedicated custom backend port and the user will enter the portal (example to example.net:3012).

I'm using HaProxy v2.4.22.

I've managed to perform the basic stuff such as usual HTTP to HTTPS redirect and add the /login path so I'm able to view the login page correctly.

About point 3 previously described, I would like to understand if is possible to catch the 302 status and redirect the flow to the correct backend.

I've tried also something like "http-request redirect location https://example.net:3000 code 302 if { status 302 } { path /redirect/ }" but the solution seems not working.

Any help would be very appreciated!

Thank you so much!

New contributor
FriendlyPotat95 is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

0

You must log in to answer this question.

Browse other questions tagged .