在 Windows 10 上,我运行了我的 vagrant,然后成功 ssh 进入我的虚拟机。安装 apache2 php5-cli php5 libapache2-mod-php
现在,当我访问localhost:8080
它时,它向我显示 apache 默认欢迎页面。如何在浏览器中访问我的网站?
这是我的 Vagrantfile 的内容
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure(2) do |config|
# Every Vagrant development environment requires a box. You can search for
# boxes at https://atlas.hashicorp.com/search.
config.vm.box = "ubuntu/trusty64"
# Create a forwarded port mapping which allows access to a specific port
# within the machine from a port on the host machine. In the example below,
# accessing "localhost:8080" will access port 80 on the guest machine.
config.vm.network "forwarded_port", guest: 80, host: 8080
end