无法安装流浪汉箱拉拉维尔家园

2022-08-30 12:30:40

我正在尝试按照此处的官方文档说明在Mac OS X上安装Laravel Homestead。

我安装了VirtualBox和Vagrant。现在,我正在尝试添加带有命令的Homestead框。过了一会儿,下载停止,我收到一个错误。它不允许我恢复下载,所以我必须删除部分下载文件并从零开始。我已经尝试过很多次了。vagrant box add laravel/homestead

我认为我的互联网连接有事情要做,因为它有点慢,而且是一个大文件。

以下是完整的代码:

$ vagrant box add laravel/homestead
==> box: Loading metadata for box 'laravel/homestead'
    box: URL: https://atlas.hashicorp.com/laravel/homestead
This box can work with multiple providers! The providers that it
can work with are listed below. Please review the list and choose
the provider you will be working with.

1) virtualbox
2) vmware_desktop

Enter your choice: 1
==> box: Adding box 'laravel/homestead' (v0.2.7) for provider: virtualbox
    box: Downloading: https://atlas.hashicorp.com/laravel/boxes/homestead/versions/0.2.7/providers/virtualbox.box
An error occurred while downloading the remote file. The error
message, if any, is reproduced below. Please fix this error and try
again.

transfer closed with 935392411 bytes remaining to read

重试后:

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.

任何帮助是值得赞赏的。


答案 1

一个。转到并删除部分下载文件,然后重试。.vagrant.d\tmp\

二.如果失败,您可以尝试使用浏览器或其他工具手动下载文件。下载后,您可以使用 导入它。vagrant box add laravel/homestead path/to/virtualbox.box

(编辑:从下面的评论中添加第二个答案。


答案 2

试试这个:
rm ~/.vagrant.d/tmp/*rm -R ~/.vagrant.d/tmp/*

另一方面。vagrant up


推荐