Forum Discussion
iRule, ProxyPass Help
I am new to iRules and F5's and have inherited an iRule called ProxyPass. It references data groups and iFiles (which there are no iFiles in the list). I'm told ProxyPass is to redirect bogus (/whatever, /imtotallylost, etc) URLs back to the /MyWebsiteOnly context URL. This was implemented long before I came along. Is there an easier way to perform the same task without using this +400 line iRule and data group? (I know this is very vague question). If I could get a more complete explanation of ProxyPass and/or a different configuration to perform the same function? Thank you for helping the "Newbie"
- Tim_E_299773Nimbostratus
Forgot to add this... Im running v13.0 on the system.
- Leonardo_SouzaCirrocumulus
Unless the iRule do some crazy stuff, 400+ lines is a lot of code. I would say that you can probably do the same with fewer lines, but without seen the code, is just a guess.
I will not, and I couldn't without seen the code, provide a full iRule for that. However, I will point you to some pages that will help you create the iRule.
To work with datagroups:
https://devcentral.f5.com/wiki/irules.class.ashx
To work with iFiles:
https://devcentral.f5.com/wiki/irules.ifile.ashx
Switch command:
https://devcentral.f5.com/wiki/irules.switch.ashx
HTTP path:
https://devcentral.f5.com/wiki/irules.http__path.ashx
You need to check if you want to use HTTP::redirect or HTTP::respond. Check the difference in this post:
https://devcentral.f5.com/questions/uri-translation-vs-httpredirect-irule-52327
- Stanislas_Piro2Cumulonimbus
Hi,
You can look at Rewrite profile (new feature in version 11.4) which can do almost the same as ProxyPass irule.
instead of irule, file, Datagroup list, you define one rule per client side / server side URLs.
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