Vagrant Homestead 开发环境部署 无法读取本地 box
我通过wget已经成功下载了box,这个box一开始的时候也成功在另外一台windows上运行了,box应该是没有问题的.
duncndeMini:Homestead duncan$ vagrant box add laravel/homestead ../virtualbox.box
==> box: Box file was not detected as metadata. Adding it directly...
==> box: Adding box 'laravel/homestead' (v0) for provider:
box: Unpacking necessary files from: file:///Users/duncan/virtualbox.box
==> box: Successfully added box 'laravel/homestead' (v0) for 'virtualbox'!
然后git clone
了Homestead
下来,然后通过bash init.sh
创建了homestead.yaml
在默认的配置下在Homestead
目录下进行vagrant up
,(按照以前在另外一台win上配置的yaml配置改过,也是不行。)
但是没法获取本地的box
,会自动到网络服务器是下载:
duncandeMini:Homestead duncan$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Box 'laravel/homestead' could not be found. Attempting to find and install...
default: Box Provider: virtualbox
default: Box Version: >= 0.4.0
==> default: Loading metadata for box 'laravel/homestead'
default: URL: https://atlas.hashicorp.com/laravel/homestead
==> default: Adding box 'laravel/homestead' (v0.4.0) for provider: virtualbox
default: Downloading: https://atlas.hashicorp.com/laravel/boxes/homestead/versions/0.4.0/providers/virtualbox.box
==> default: Box download is resuming from prior download progress
An error occurred while downloading the remote file. The error
message, if any, is reproduced below. Please fix this error and try
again.
HTTP server doesn't seem to support byte ranges. Cannot resume.
这里的报错自然就是大家都知道的原因。
但是我想知道为什么,本地的box没有成功获取呢?
vagrant box list
是有信息的
duncandeMini:Homestead duncan$ vagrant global-status
id name provider state directory
------------------------------------------------------------------------
dec5845 default virtualbox running /Users/duncan/project
所以完全不知道为什么本地box没有成功获取~!小菜鸟求解~
推荐文章: