GlassFish redirect www to non-www domain
Is it possible to redirect users from www.domain.com
to domain.com
?
I'm running GlassFish 3.1.1 with JSF/EJB app in root context (/).
It wo开发者_JS百科uld be also nice to keep context path/params:
www.domain.com/subpage/title/ -> domain.com/subpage/title/
Redirect from docroot to an external url in glassfish discusses three ways to do this - every single one requires some extra efforts:
- Modify the DNS mapping in your DNS server;
- Use UrlRewriteFilter; or
- Put a web server - like apache httpd - in front of glassfish.
精彩评论