Dan
Dan

Reputation: 363

How to access a local asp.net server on OSX through parallels 7.

I'm running visual studio 2010 on Windows 7 through parallels on my mac. I want to be able to access its local host on osx for testing purposes. I really have no idea what steps that I'd have to take to do this, so any help at all would be appreciated.

Upvotes: 1

Views: 4164

Answers (3)

user0129e021939232
user0129e021939232

Reputation: 6355

If you go to Terminal and type in the command "ifconfig" and look for the "vnic1" section which is the last section to be printed and it has an ip address called "inet" e.g. "10.37.129.2" this will take you directly to local host.

If it doesn't work you must ensure that your parallels is set to a shared network under the preferences network section.

Upvotes: 0

Nick Bork
Nick Bork

Reputation: 4841

The answer is NO:

https://serverfault.com/questions/82899/can-i-access-cassini-from-a-remote-machine

Cassini, the built in web server, only listens on Localhost.

The recommended way to do it is to setup IIS 7 on Windows 7 and attach the Visual Studio debugger to your application pool process.

If you can get a tool like Fiddler for Mac that supports reverse proxy abilites you could try:

http://abhishekdev.posterous.com/how-to-access-a-cassini-iis-for-web-projects

Or maybe setup a SSH proxy (VM as the server and ssh tunnely from Mac to VM)?

Upvotes: 1

Ted
Ted

Reputation: 7251

  1. Map the VM's IP to a domain in your /private/etc/hosts file in OSX (i.e. testsite.local) or just access via the VM's IP directly. Of course, for the same, map in your VM's host file as well (i.e. c:/Windows/system32/drivers/etc/hosts map 127.0.0.1 to testsite.local)

  2. Map appropriately in IIS in VM.

  3. Make sure applicable port/s are opened in your VM Windows firewall (standard port 80 and 443 usually enough).
  4. Done.

I very rarely use the built-in VS Development Server, so can't say anything on that.

Troubleshooting:

  1. Make sure it works in the VM first ;-)
  2. Turn off your firewall temporarily to make sure it's not a firewall issue.
  3. Make sure you've got your network settings set applicable. I haven't been working with a Mac for all that long, so haven't bothered testing with anything other than bridged.

Upvotes: 2

Related Questions