【发布时间】:2021-12-10 01:18:46
【问题描述】:
这是 Homestead.yaml 配置:
ip: 192.168.9.10
memory: 2048
cpus: 2
provider: vmware_desktop
authorize: ~/.ssh/id_rsa.pub
keys:
- ~/.ssh/id_rsa
folders:
-
map: 'C:\Users\Khalil\RestfulAPI'
to: /home/vagrant/restfulapi
sites:
-
map: restfulapi.dev
to: /home/vagrant/restfulapi/public
php: "8.0"
databases:
- homestead
features:
-
mariadb: false
-
ohmyzsh: false
-
webdriver: false
name: restfulapi
hostname: restfulapi
我也将它添加到主机文件中:192.168.9.10 restfulapi.dev
当我使用 http://restfulapi.local 而不将其直接映射为站点时它可以工作,因为我猜 *.local 是默认值?
运行restfulapi.dev 需要永远加载然后给出“连接超时”,从我的主机ping IP 响应TTL expired in transit 4 次并以a 结束
Ping statistics for 192.168.9.10:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
我可以正常运行vagrant ssh和ping 192.168.9.10并得到响应,并且当我运行ip address show时它也在机器上配置为eth1。
尝试过配置、销毁虚拟机、从头开始设置所有内容。
【问题讨论】: