This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
When I debug my application, written in NetBeans and using the bundled Glassfish V2.x server, when the application starts, Netbeans fires up the browser.
The browser is fed the URL for the proper <Context path> in context.xml
All this works great.
Except that the hostname is always "localhost" which works, but makes testing on other devices, say an iPad, hard. So if my context is "/myapp"
then the URL is http://localhost:8080/myapp/
The computer that I'm developing on has a fixed IP and a name defined in the DNS system. What I want is to have the host name used, so if the host is fast.pfarrell.com,
I want the URL to be http://fast.pfarrell.com:8080/myapp/
This has to be some configuration parameter in either Netbeans or in Glassfish, but I can't find where. I can't even find anytihng close in the documentation or googling.
I assume in production contexts, the incoming URL for the HttpServletRequest is filled in. But for testing, I'd like it to look and feel real