Saturday, January 29, 2011

heroku not working with rvm on ubuntu

turns out when rvm installs ruby 1.9.2 on ubuntu, it will keep compiling even if some libraries aren't there. so if you don't have ssl libraries, it will compile ruby, but you just won't get to require 'net/https'. which is cool. i prefer this behavior. but it leads to some head scratching when later on, trying to install and use heroku keys:add, you get messages like the following:
no such file to load -- net/https. Try running apt-get install libopenssl-ruby
(See full trace by running task with --trace)

wtf? so ok, sudo aptitude install -y libopenssl-ruby and try again.

but that same message comes up! i tried other stuff, like rvm package install openssl and still got the same error message. uninstalled the gemset and reinstalled. still no dice. uninstalled rvm completely rvm implode and reinstalled bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head ), and that did the trick. in retrospect, all i probably needed to do was recompile 1.9.2. and even then, i probably just needed to recompile the openssl part with the libopenssl-ruby library installed on my system.

in short


so in short, what i needed to do was:

sudo aptitude install -y libopenssl-ruby{,1.9.1}
rvm implode
bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
gem install rails
gem install heroku
heroku keys:add

and then continue with the rails tutorial heroku part

related posts


here's some posts i found while troubleshooting just now:

Where am I?