vagrantの1.1以降はgemではなくパッケージインストールの形になったようなのでとりあえず最新の1.2.1をインストールしてみた。
vagrant box add がエラーになる
早速適当なboxを動かsしてみようと思ったんだが、何故かbox addしようとすると↓のようなエラーが出てbox addが出来ない…。
# vagrant box add ce6 http://developer.nrel.gov/downloads/vagrant-boxes/CentOS-6.4-x86_64-v20130309.box
Downloading or copying the box...
An error occurred while downloading the remote file. The error
message, if any, is reproduced below. Please fix this error and try
again.
Failed initialization
ちなみにMacのvagrant-1.2.1は問題なく動いたのになぁ…。
適当パッチ
で色々追ってみたらどうやら curl の起動に失敗しているようだ。PATHがどこでどうなって駄目な感じになったのかは追ってないが、とりあえず以下のように修正したら直った。
# diff -r /opt/vagrant/embedded/gems/gems/vagrant-1.2.1/lib/vagrant/util/downloader.rb.orig /opt/vagrant/embedded/gems/gems/vagrant-1.2.1/lib/vagrant/util/downloader.rb
122c122
< Subprocess.execute("curl", *options, &data_proc)
---
> Subprocess.execute("/usr/bin/curl", *options, &data_proc)