Forum Discussion
Tony2020
Nimbostratus
Apr 28, 2017Match & redirect based on URIs to another site with similar URIs structured
Hi all, I would like to know if anyone can help provide recommendations on this iRUle where it will only match based on the URIs from the old site, and from there redirect to a new site with simi...
Stanislas_Piro2
Cumulonimbus
Apr 28, 2017Hi,
looking at your question, I think irule / Datagroup is not the best solution but LTM Policies.
You can create one policy with rules:
-
rule 1:
- condition : HTTP uri path starts with
/uri1/ /uri2/ /uri3/ /uri4/ /uri5/ /uri5/ - action http-reply
tcl:"http://my.newsite.com[HTTP::uri]"
- condition : HTTP uri path starts with
-
rule 2:
- condition : HTTP uri path starts with
/uri6/ /uri7/ /uri8/ /uri9/ - action http-reply
tcl:"http://my.newsite.com2[HTTP::uri]"
- condition : HTTP uri path starts with
the tcl format is supported since version 12.0. In previous version, the
tcl: string must be removed.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