I have built a typical Hashi Nomad-Consul cluster stack with the below setup:
3 nodes of Nomad Servers
3 nodes of Nomad Client servers
3 nodes of Consul Servers
Consul agent running on all Nomad servers, Consul servers and Nomad clients for service discovery
Fabio LB systemd service on Nomad Client servers for load balancing the services and making them accessible via single endpoint using tags and urlPrefix
Operating system is RHEL8
Nomad Client servers are thrown into BigIP F5 pool with service port as 9999 for making the Fabio load balanced services available externally. Configuration wise, everything works just fine for single endpoint micro services.
However the the problem appears when theres multi-url links and pages within on a site or service deployed.
For example, if we wanted to host a simple promotional website which has links within to navigate it all falls apart.
Here's an example stanza for service for Fabio to pickup:
service {
name = "promo-nov"
port = "http"
tags = [
"urlprefix-/uberpromo/ strip=/uberpromo",
]
check {
type = "http"
port = "http"
path = "/"
interval = "2s"
timeout = "2s"
}
}
I can get to home page of the promo site if I use the the F5 VIP URL with '/uberpromo/' tag. However, if I click a link on the webpage, for example, 'Contact Us' on the home page which should ideally take me to https://f5-hosted-url.com/uberpromo/contactus.html it drops '/uberpromo/' and takes me to the url https://f5-hosted-url.com/contactus.html and throws page not found.
I have built a typical Hashi Nomad-Consul cluster stack with the below setup:
Nomad Client servers are thrown into BigIP F5 pool with service port as 9999 for making the Fabio load balanced services available externally. Configuration wise, everything works just fine for single endpoint micro services. However the the problem appears when theres multi-url links and pages within on a site or service deployed.
For example, if we wanted to host a simple promotional website which has links within to navigate it all falls apart. Here's an example stanza for service for Fabio to pickup:
I can get to home page of the promo site if I use the the F5 VIP URL with '/uberpromo/' tag. However, if I click a link on the webpage, for example, 'Contact Us' on the home page which should ideally take me to https://f5-hosted-url.com/uberpromo/contactus.html it drops '/uberpromo/' and takes me to the url https://f5-hosted-url.com/contactus.html and throws page not found.
And if I use the url https://f5-hosted-url.com/uberpromo/contactus.html directly it works but if I click 'home' on the page it breaks again. Takes me to https://f5-hosted-url.com dropping '/uberpromo/'.
Is there a solution or way around this problem. Please suggest!