Forum Discussion
DaveC_53879
Nimbostratus
May 02, 2012Configsync failing due to rule syntax
I have a new rule that works correctly redirecting traffic from one domain to another domain with an extra dash in the domain name. Pretty straightforward. But when I try to sync the configs to the ...
Joel_Moses
Nimbostratus
May 02, 20129.4.6 had some oddities about placement of curly-braces in iRules. Try this:
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::host]] {
"www.site1.com" -
"site1.com" {
HTTP::redirect "http://www.site-1.com[HTTP::uri]"
}
}
}
I've seen instances where the 9.x parser seemed to think consecutive curly-braces on the same line marked the end of the iRule in the config erroneously. It's been fixed in 10.x and above.
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
