0

I use Vagrant and Chef to create new servers when I am developing. I want to start out on Ruby on Rails so I am setting up a server. Everything is working but Ubuntu and Rails are reporting different Ruby versions.

Ubuntu 12.04: ruby -v = ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-linux]
Rails = 1.8.7 (x86_64-linux)

I don't want Ruby 1.8.7 on the system at all but I can't get rid of it. Is there anyway to set a default Ruby version?

I don't want top use RVM or similar.

Craig Ward
  • 2,425
  • 5
  • 33
  • 51
  • What do you mean with "Rails reports a different ruby version"? Unless you use RVM, RBENV or similar, there is only one Ruby version that Rails will use. Note though Ruby != Rails, i.e. Rails has a version on its own! – emrass Oct 11 '12 at 15:12
  • Did you find a solution to this problem? Please don't forget to mark an answer as correct! :) – sethvargo Jan 02 '14 at 22:49

2 Answers2

0

try this aptitude purge ruby

and then install the latest version or the version you want

came across this post in stackoverflow How do I make Ruby 1.9 the default Ruby on Ubuntu?

Community
  • 1
  • 1
Ross
  • 1,562
  • 1
  • 15
  • 26
  • No joy, I just get the following `No packages will be installed, upgraded, or removed. 0 packages upgraded, 0 newly installed, 0 to remove and 102 not upgraded.` – Craig Ward Oct 11 '12 at 12:55
  • Thats not working either. Ubuntu says no other versions of Ruby are installed and there is no reference to any 1.8 packages. Think this might be something to do with Vagrant – Craig Ward Oct 11 '12 at 13:14
0

This did the trick.

https://github.com/royratcliffe/VagrantBaseBoxes

Craig Ward
  • 2,425
  • 5
  • 33
  • 51