views:

43

answers:

3

I am deving a webpage. For testing purposes i want to access the webpage via my VM and possibly ask a friend to mess with it remotely. The app is running in visual studios 2008. I put set my router DMZ to my IP address and i tried connecting via VM and remotely. No luck. How do i config visual studios to listen outside of the machine?

+1  A: 

I'm not sure on the answer to this, and this might sound a bit obvious so don't mark me down for it as I'm just trying to be helpful, but are you using the port the development web server is running on in the url? e.g. http://1.2.3.4:5678

Edit

The answer to this question provides a work around you may be able to use.

Dave7896
Yes. Also i tried putting my network ip and replace localhost, and it did not connect. To double check i write \\192.168.1.122 in explorer and it did successfully connect to my comp. This is on my pc and not VM so it still was the local comp.
acidzombie24
+2  A: 

The visual studio web server is hardcoded to not allow access remotely. You need to use a proxy server running on your local system on another port to allow access to it, or publish the site in another webserver that DOES allow remote connections, like IIS.

Eg: VisualStudio serving the site on http://localhost:23456, set up a reverse proxy on port 82, which goes to localhost:23456, and then when you connect to http://[your computers ip]:82 (http://192.168.0.102:82 for example), you'll get the site running in visual studio.

Note one downside to the proxy method is if someone else is accessing the site, and you have breakpoints set, they will be triggering them remotely and interfering with your use of the site (I believe this is why it's disabled remotely). Better to publish via IIS to avoid this problem.

gregmac
+1. I'll give dave the answer for the thread link and bc he has lower points/tried more.
acidzombie24
Thanks acidzombie24
Dave7896
+1  A: 

I'm going to assume you have a version of Windows that allows you to use IIS.

But why not create a virtual directory in IIS, point it to your website and then give your friend that link.

So locally you'd access it like this: http://localhost/mysite

Your friend would access it like this (assuming your router configured correctly and using port 2222 redirecting to local port 80): http://your.I.P.here:2222/mysite

Then you should be good to go.

Clarence Klopfstein
And, if you want to point this to your actual project's code, just make sure you point it to the correct folder (debug/release). It would be best to have a "Build" directory outside of the actual project's directory, to which you "release" a build periodically.
Jim Schubert
No IIS installed :(. I heard someone say every nonhome windows has it, i am using windows 7 ultimate and VS2008 told me it does not have it installed.
acidzombie24
From my quick searching, Windows 7 Ultimate supports IIS 7. You likely just have to install it.http://technet.microsoft.com/en-us/library/cc725762.aspx
Clarence Klopfstein