Forum Discussion
iRule help for beginner
hi,
Have a very easy question.I am looking for an i rule to do the following. FW Public IP > LB listneing on Port 80 > Real Server Pool listening on Port 90xx Service is advertised as follows to internet ... http://x.x.x.x/NameofService. I only want to advertise this exact URL/service and all other requests to get an error page back from F5 ( eg Service Unavailable ) Currently I have only one server deployed behind this VIP , probably will be more but not at the moment.
Thanks in advance
1 Reply
- Kevin_Stewart
Employee
Assuming there's a single DNS entry that resolves to the virtual server IP, and you only really care about the URI, something like this might work:
when HTTP_REQUEST { if { not ( [string tolower [HTTP::uri]] equals "/nameofservice" ) } { HTTP::respond 200 content "Service Unavailable" } }
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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