Forum Discussion
Mike_Monti
Mar 18, 2022Nimbostratus
iRule that saves subdomain
I have a number of different subdomains (wwwdev, wwwapps, things like that) and I want to use an iRule to force the domain from .com to .org. Example force anyone that types in wwwdev.mydomain.com ...
- Mar 18, 2022
Hi Mike,
Can you try this iRule?
when HTTP_REQUEST { if { [HTTP::host] ends_with ".mydoamin.com" } { HTTP::redirect https://[string map {".com" ".org"} [HTTP::host]][HTTP::uri] return } }
Mike_Monti
Mar 21, 2022Nimbostratus
Thanks for this, I've thrown it into dev and am checking it in a few places. So far so good!
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