Forum Discussion
DarkSideOfTheQ_
Nimbostratus
Jan 23, 2009irule to return status code
I'm still learning here, so bear with me. I am trying to write an irule that will catch requests trying to pull content from a specific set of hosts (ex. myserver1.domain.com, myserver2.domain.com, my...
Colin_Walker_12
Jan 23, 2009Historic F5 Account
Denny's right, so what you'd want instead is something like:
when HTTP_REQUEST {
switch -glob [HTTP::host] {
"*myserver1.domain.com" -
"*myserver2.domain.com" -
"*myserver3.domain.com" {
HTTP::respond 200 content "Response from LTM iRule"
}
}
}
Of course you can get a lot more detailed in the response you want to send, too. Take a look at the HTTP::respond wiki page for some examples - Click here
HTH,
Colin
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