Last active
August 29, 2015 14:20
-
-
Save rbg246/5af38b48afb45bd77fa8 to your computer and use it in GitHub Desktop.
Virtual Box - Setup, linking Virtual box with your computer's localhost and vhosts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Reference: http://stackoverflow.com/questions/1261975/addressing-localhost-from-a-virtualbox-virtual-machine | |
In Virtual Box - running Windows: | |
You can reach your localhost via: | |
http://10.0.2.2 | |
If you need to link to vhosts on your localhost though you need to update the virtual box's hosts file | |
Enable Notepad to be run as administrator | |
http://www.7tutorials.com/how-run-programs-administrator-windows-7 | |
Edit the hosts file | |
windows/system32/drivers/etc/hosts using notepad as admin app | |
and enter: | |
10.0.0.2 vhosted-domain.dev | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment