Jump to content

Recommended Posts

Hi all,

 

I have a linux VM on my Windows computer and I use that for testing. I also have a xampp installed on my Windows machine and that is the default local host for the windows machine. 

 

So is it possible for me to make the VM act as a localhost for the windows machine as well? If so,  how? I hope that my question is clear.

 

I need to do this since I it's difficult to debug my flash files as the rest of the project is on the VM. I don't want to take move all the stuff back into the windows machine just to test the flash files there. 

 

Thanks all !

 

 

If you mean make http://localhost/ point to the VM, then afaik no you cannot do that (unless you proxy it).

 

What you can do is edit your hosts file and add a new entry that points to your vm's IP address, say vm. Then you could use http://vm/ to connect to your VM.

  • Like 2

To follow up on Kickens suggestion, here are instructions for how to find the Windows hosts file. It's just a text file so notepad or any other text editor will do.

 

I don't know what virtualization tech you are using, but they all have ways of sharing folders. This is the typical way that people develop. All your source is in a shared folder, so you can edit and see the results reflected by the serving of content from the VM.

 

The hosts file is a nice way to do that, but if you do follow that I would suggest you use a domain.tld. This is due to the issues that can occur with cookies when you don't use a "normal" domain name.

 

The special reserved tld's in RFC2606 are: .test, .example, .invalid and .localhost. I will use something like:

 

192.168.168.4  www.someproject.test
  • Like 1

Hi, Thanks Kicken & Gizmola,

 

Thanks for the reply and suggestions.  I am. in fact, already doing as suggested by you both. 

 

The problem lies with flash files that (i think) can be run only in the windows environment.To test locally on flash therefore I needed to work in windows and so needed the localhost on windows. 

 

In any case, I have eventually ported portions of the code in windows and am able to test locally now using localhost. 

 

Thanks very much !

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.