• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 447
  • Last Modified:

domain redirection with cname or A

Hi,
right now I can access my service only by IP address: XX.XXX.XXX.XXX:8080/NameHere/
I need to specify port and name of my app. Is it possible to cover that with subdomain entry?
I know that with a type A redirection I can get rid of IP address but is it possible to loose port and application name at the end?
0
static86
Asked:
static86
2 Solutions
 
nemageeCommented:
Hi there static,

You'll have to take this on one step at a time -- DNS can't take care of all your requirements. First I would suggest you create an A record so that you can refer to this host by name instead of by IP address. That will convert xx.xx.xx.xx to servername.company.com. Next, if this server does not already host something on port 80, then you could listen on port 80 for traffic and using an .htaccess file redirect your users both to the new port (8080) and the subdirectory/application name (/NameHere/).

That way, when a user hits servername.company.com with a browser, they are automatically redirected to servername.company.com:8080/NameHere/ .

If this makes sense, I can help you write a little .htaccess file to do your redirection.
0
 
Frank ContrepoisVP Technical SalesCommented:
No, port and app name cannot be inserted in the DNS entry as DNS manage the conversion from domains to ip but is not bound to any application.

You do not have to write www.yahoo.com:80 because your browser knows the port is 80, not dns.

You can do what you're asking for using apache and mod_alias or mod_rewrite + mod_jk if your app is on a tomcat

USER -------- APACHE on port 80 so no need for the url to include the port -------mod_jk------ tomcat
                    Can reconvert NameHere.domain.com to
                      NameHere.domain.com/NameHere
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Protect Your Employees from Wi-Fi Threats

As Wi-Fi growth and popularity continues to climb, not everyone understands the risks that come with connecting to public Wi-Fi or even offering Wi-Fi to employees, visitors and guests. Download the resource kit to make sure your safe wherever business takes you!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now