Best method to redirect internal DNS to external website?

Posted by ProfessionalAmateur on Server Fault See other posts from Server Fault or by ProfessionalAmateur
Published on 2012-09-20T15:34:50Z Indexed on 2012/09/20 15:39 UTC
Read the original article Hit count: 246

We host several web based applications outside of intranet. The URL's to these applications are long, complex and overall not user friendly. Ex:

http://hostingsite:port/approot/folder/folder/login.aspx <-- (production)
http://hostingsite:port22/approot/folder/folder/login.aspx <-- (dev)
http://hostingsite:port33/approot/folder/folder/login.aspx <-- (test)

I'd like to create an internal DNS entry to allow users to access these sites with ease. Ex:

http://prod  --> http://hostingsite:port/approot/folder/folder/login.aspx
http://dev --> http://hostingsite:port22/approot/folder/folder/login.aspx

I'm not familiar with the DNS process and setup, as far as I know a DNS can only be redirected to an IP, but not to subdomains for directory paths as described above? Is this a correct assumption?

I am thinking for throwing up an internal webserver that will listen to the internal DNS entries and redirect to the external sites.

http://prod --> [internal webserver] --> redirect --> http://hostingsite:port/approot/folder/folder/login.aspx

Is there a better way to do this?

© Server Fault or respective owner

Related posts about redirect

Related posts about web-hosting