Neil,
It doesn't apper that there are multiple host names involved so you only need to match on the HTTP::uri.
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::path]] {
No path goes to pool-1
/ {
pool pool-1
}
paths that start with /account go to pool-2
/account* {
pool pool-2
}
paths that start with /service go to pool-3
/service* {
pool pool-3
}
all other requests go to pool-4
default {
pool pool-4
}
}
}
Also, it is hard to tell from your example but, it looks like you are also trying to define the "default context" or "default document" for a given path. i.e. If request comes in for /account then rewrite or redirect to /account/path/index.html.
When I get requests like this from the server guys I usually tell them that is the server's job (:-D) to define the default context/document but, it can be done on the LTM. First I would sugest a redirect and NOT a rewrite. Also, you just have to be careful to to use an effective "equals" and not a "starts_with" or you will end up with an infinite redirect. Let us know if that is what you are trying to do and we can help with the irule.
Joe