Installing Ruby on Rails on Ubuntu 10.04: A Living Nightmare
Solution 1
From that tutorial (which appears to be down at the moment), these lines:
apt-get install build-essential
apt-get install ruby rdoc libopenssl-ruby
Should be replaced by:
apt-get install ruby-full build-essential
And everything works fine beyond that point. My guess is that some critical binaries are being left out when attempting a "minimal" install of ruby. Answer obtained via the RoR mailing list.
Solution 2
Install Ruby Version Manager!
Seriously! I wish I would have done this sooner. Ruby Version Manager makes it possible to run multiple versions of Ruby, each with their own set of gems, and switch between the different versions seemlessly. Plus, you won't have to use sudo
anymore. Plus, it's super easy to install, so you should do it!
Solution 3
Have you tried to install?
apt-get install libopenssl-ruby
and perhaps install your Gems again (including rails)?
Related videos on Youtube
emptyset
Updated on September 17, 2022Comments
-
emptyset over 1 year
Update #3: Starting over from scratch, shortened this post, decided to re-install a clean copy of Ubuntu 10.04 on a VM and go through the walk-through again. So, all the steps go without a hitch. As root:
root@ubuntu:~/rubygems-1.3.7# ruby -v ruby 1.8.7 (2010-01-10 patchlevel 249) [x86_64-linux] root@ubuntu:~/rubygems-1.3.7# gem -v 1.3.7 root@ubuntu:~/rubygems-1.3.7# rails -v Rails 2.3.8
Now, as myself (in a separate term):
emptyset@ubuntu:~$ ruby -v ruby 1.8.7 (2010-01-10 patchlevel 249) [x86_64-linux] emptyset@ubuntu:~$ gem -v /usr/local/lib/site_ruby/1.8/rubygems.rb:10:in `require': no such file to load -- rubygems/defaults (LoadError) from /usr/local/lib/site_ruby/1.8/rubygems.rb:10 from /usr/local/bin/gem:8:in `require' from /usr/local/bin/gem:8 emptyset@ubuntu:~$ rails -v bash: /usr/bin/rails: Permission denied
So, this appears to be a permissions issue, but I don't understand why. Specifically, if I have to start making things
go+rx
all over the place, I really need to understand which specific files need the permissions change.-
elf.xf over 13 yearsA little late to the party...but this is my 10.10 walkthrough: ryancsmith.tumblr.com/post/2082812923/…
-
-
zengr almost 14 years
-
emptyset over 13 yearsI'll definitely try it the next time I have to do some Ruby work for a client. :)