Forum Discussion
155
Nimbostratus
Jun 22, 2020iRule insert IP::remote_addr to uri redirect
Hi, In our scenario, we have public-facing URL https://domain.com. I need to receive traffic from that url and forward it to one of the pool nodes as below: https://subdomain.[IP::remote_addr]...
youssef1
Cumulonimbus
Jun 23, 2020Hello,
For your need you have to set your hostname in LB_SELECTED event when the backend server will be selected:
when LB_SELECTED {
HTTP::header replace Host "subdomain.[LB::server addr].com"
log local0. "serverIP $serverIP"
log local0. "Host: [HTTP::header value Host]"
}So you don't need to insert the port, this one will be redirect automaticly (by default in your VS the Port Translation is checked).
kee p me in touch if you need more details.
regards.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects