You need to set up the network or port mapping of the virtual machine.
After setting up the network, you can access the virtual machine through IP. You can refer to http://www.douban.com/group/topic/15558388/
If you set up port mapping, you can map a port on the host to a port on the virtual machine, so that you can access the virtual machine's services using localhost: port number. You can refer to http://sjsky.iteye.com/blog/909610 http://hi.baidu.com/quqvgmgbexbdgod/item/91da255f724d9d09e7c4a56d
In addition, it is recommended to use Vagrant. These settings have official documents for reference, which is very convenient.
You need to set up the network or port mapping of the virtual machine.
After setting up the network, you can access the virtual machine through IP. You can refer to http://www.douban.com/group/topic/15558388/
If you set up port mapping, you can map a port on the host to a port on the virtual machine, so that you can access the virtual machine's services using localhost: port number. You can refer to http://sjsky.iteye.com/blog/909610 http://hi.baidu.com/quqvgmgbexbdgod/item/91da255f724d9d09e7c4a56d
In addition, it is recommended to use Vagrant. These settings have official documents for reference, which is very convenient.
Create a host-only connection for the new virtual machine; then access its IP, such as
192.168.56.101
.