Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

In my previous job, I remember that if I launched tomcat, if someone else went to

myname.companyName.com

it would be the equivalent of me going to

http://localhost:tomcatport

but only if we were both connected to the same network.

How do I go about mimicking this behavior? I just want to be able to IM a boss/co-worker a link and say "look at this", instead of bringing them over to my machine.

share|improve this question

migrated from stackoverflow.com May 2 '11 at 18:59

This question came from our site for professional and enthusiast programmers.

    
Certainly a valid question. However, you'll find the folks at ServerFault will have a higher likelihood of answering this. (I see someone has a vote for SuperUser, I would disagree. This seems more like a networking/server administration issue than the power user of a program issue.) –  corsiKa May 2 '11 at 15:48

2 Answers 2

You have to know the name or IP of your computer on the network. If you're on Windows, you can go to a command prompt and type "ipconfig" to get your IP address. Or go to Control Panel > System > Computer Name, and your computer's name will be in the "full computer name" field.

I forget how to get this in Linux off the top of my head. If you need that, post a reply and I'll check.

share|improve this answer

The answer is "it depends."

The easiest way is to find out the IP address of your machine and send your boss/coworker that URL (along with the port number). For example, if the IP address of your machine is 10.0.2.1, your Tomcat URL is:

http://10.0.2.1:8080/

(assuming you have Tomcat running on port 8080 per default.)

Be aware that if your machine uses DHCP to lease its IP address, your IP address may change periodically, so you'll need to look it up every time you send the link.

If you only have a few hosts on your network and no IT support and are using fixed addresses, you can edit the HOSTS file on your boss's/coworker's machine. Map myname.companyName.com to your IP address, then the following URL is valid, but ONLY on your boss's/coworker's machine:

http://myname.companyName.com:8080/

If your company has an IT department or you're using DHCP with dynamic DNS, your best bet is making a request to your IT staffers. They can probably give you a workable solution in a short amount of time.

share|improve this answer
    
For my purposes, the first solution works perfectly, thanks! –  RankWeis May 2 '11 at 16:29

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.