Nov 24, 2015 To Bundle or not To Bundle
Short Answer: Not To Bundle
I recently tore down and recreated my local BOSH lite installation. Re-cloned the repos - everything. Imagine my surprise when I ran into this little gem (har har see what I did thar):
$ ./bin/provision_cf ... /scripts/generate-bosh-lite-dev-manifest /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- bundler/setup (LoadError) from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require' Can only target Bosh Lite Director. Please use 'bosh target' before running this script.
This actually ended up being caused by an OpenSSL issue in El Capitan. Specifically, it appears on a cursory Google search that El Capitan doesn't include OpenSSL. To run BOSH lite locally you will need OpenSSL, so the quickest way to fix this if you have Homebrew is:
$ brew link openssl --force Linking /usr/local/Cellar/openssl/1.0.2d_1... 1548 symlinks created
Arriving at that solution was not as direct as I would have liked as there are a couple ambiguous things going on in this error. The bit about
bundler seems to indicate, well, a
bundler problem. Then there is message that follows the ruby/bundler errors that seems to indicate that I am not targeting a BOSH lite, which of course I am:
$ bosh target Current target is https://192.168.50.4:25555 (Bosh Lite Director)
gem install bundler ; bundle install did update some gems, and also brought me back face-to-face with my old friend the nokogiri install error, but ultimately did not resolve this issue.
So how did I ultimatley come across the OpenSSL issue? A suggestion from a co-worker who is Ruby-familiar mentioned the issue about bundler missing OpenSSL on El Capitan and sort of wondered aloud if that could be the cause of the issue and that turned out to be it.