Forum Discussion
Dominique_10413
Nimbostratus
Mar 10, 2009iRule to route https traffic to different pool based on hostname
We have a rather urgent requirement to route HTTPS traffic to two different hosts based on the hostname that was requested.
Effectively what we need to do is have 1 public IP address (l...
hoolio
Cirrostratus
Mar 10, 2009If you do end up going with option one, you can use HTTP classes in 9.4+ or an iRule to select the pool based on the requested host header. For details on using HTTP classes, you can check the LTM configuration guide for your version. Here is an example iRule:
when HTTP_REQUEST {
Check requested host header (set to lowercase)
switch [string tolower [HTTP::host]] {
"www.site1.com" {
pool site1_pool
}
"www.site2.com" {
pool site2_pool
}
default {
pool default_pool
}
}
}
Aaron
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