Forum Discussion
eben_259100
Cirrostratus
Try setting the new HTTP::host as a variable. then call it in the redirect. when HTTP_REQUEST { if { [class match [[string tolower [HTTP::uri]] starts_with DatagroupNAME ]] } { HTTP::respond 302 location "http://$[HTTP::uri]" } }
You could also use a Switch [HTTP::uri] to achieve this.
eben_259100
Jun 23, 2017Cirrostratus
when HTTP_REQUEST{ switch [HTTP::uri] { "/lorl/"- "/jc.app.settings.svc.webhost/"- "/jc.leader.joe.webhost/"- "/jc.app/settings.svc.webhost/" { HTTP::redirect "http://new.domain.com/[HTTP::uri]"}
}
}