Forum Discussion
2019F5DevCentra
Cirrus
Jul 22, 2021DNS Redirect by Port in Header
I am unable to get his to function properly and I believe it's the logic I have.
I am attempting to pass all traffic through with the exception of a port coming across in the url with the same fqdn and then passing that to another pool with the proper port on the back end.
Example:
happy.com
happy.com:1001
when HTTP_REQUEST {
"happy.com" {
if { [HTTP::host] contains ":"} {
HTTP::header replace Host "[getfield [HTTP::host] : 1]"
pool HAPPY_1001
}
pool HAPPY_443
}
}
something seems odd with the irule, the "happy.com" cant just start there. did something get lost?
beyond that what doesn't work exactly? doesn't the contains ":" match?
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