aspose file tools*
The moose likes Struts and the fly likes Why I need multiple forwards so my domain points to my application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Why I need multiple forwards so my domain points to my application" Watch "Why I need multiple forwards so my domain points to my application" New topic
Author

Why I need multiple forwards so my domain points to my application

Sanjay Virkar
Greenhorn

Joined: Apr 03, 2005
Posts: 19
I am hosting a struts based website on my Linux machine on Tomcat on port 8080. I have defined virtual server on my router and expose port 9999 and foward it to my linux box. So when someone enters http://my.ext.ip.address:9999/myapp in browser, it is forwarded to my linux machine on port 8080 to application named- myapp.

As I use dsl and don't have static IP, I have to use dynamic dns- to keep my current external IP up-to-date on name server.

I have purchased a domain name and I forward it to dynamic dns1.

All of this setup is working fine with out any problem.


But from outside one has to enter- http://www.mydomain.com:9999/myapp to reach to my application. To avoid this I use one more dynamic dns2 host (as they are anyway free) to redirect one more time so when one enters
http://www.mydomain.com - they reach to my application. This second dynamic dns2 is kept current by my router automatically.


My question is why have these multiple redirections? How can I simplify it so that nameserver itself will redirect it to correct port and application?
Chris Boldon
Ranch Hand

Joined: Aug 10, 2006
Posts: 190
This has nothing to do with Struts. It is because you have a dynamic IP. Dynamic IPs are not meant for hosting.
Sanjay Virkar
Greenhorn

Joined: Apr 03, 2005
Posts: 19
Originally posted by Chris Boldon:
This has nothing to do with Struts. It is because you have a dynamic IP. Dynamic IPs are not meant for hosting.


Dynamic IP and inability to host website issue has already been resolved by using dynamic dns and forwarding to one more dynamic dns.

And you are right, this may not be Struts issue but could be server.xml issue where I can make my application default app so if I don't provide port number and application name in browser, request is still routed to my application
Chris Boldon
Ranch Hand

Joined: Aug 10, 2006
Posts: 190
Still not a Struts issue.

Modjk may be what you're looking for though. JK mount the app.
 
Consider Paul's rocket mass heater.
 
subject: Why I need multiple forwards so my domain points to my application