Koozali.org: home of the SME Server
Obsolete Releases => SME 9.x Contribs => Topic started by: pcdoc on May 29, 2017, 10:18:42 AM
-
I want to install ruby on rails on a 9.2 VM and am having some issues. It works well on a centos 6.7 VM, but is installing rub 1.8.7 and I need >1.9.7
The only info on this site is for sme7 and says to setup the centos-testing repo... not much use on 9.2 though.
I have the latest version of gems on the VM, but need to install a later version of ruby to get rails running. I would rather not compile ruby as this could get messy down the track if it needs updating.
Any thoughts on what repo I could use? or another way around it?
Thanks all.
Matt Holmes
-
hi..
you'd start from here:
https://wiki.contribs.org/Software_collections
HTH
-
Thanks Stefano. Its strange, I did a search for ruby on rails in wiki, forums, howto etc, but the software collections item did not show.
So I already had software collections installed (for nextcloud), when I went to install ruby with enablerepo=centos-sclo-rh and all others disabled, it could not find ruby. I tried without disablerepo and the only ruby shown was 1.8.7.
I ran yum list available --disablerepo=* --enablerepo=centos-sclo-rh | grep ruby and it showed ruby193 and ruby200 available. I installed ruby200 with its dependencies but when running ruby -v or ruby200 -v the VM put its hands in the air and went silent.
So, I tried installing ruby193 with the same result. I also went into /opt/rh/ruby193 and ran >sh ./enable as well as the v8314 folder.
Same result.
edit - OK, sort of have it running. Have tried with both ruby193 and ruby200, I can get the version up with >scl enable ruby200 'ruby -v' but when I go to install rails using gem it complains I don't have ruby-2.2.2 now.
Last error message is 'activsupport requires Ruby version >= 2.2.2.
Thoughts?
Is there some documentation I have been unable to find on the site that I am missing?
-
but when running ruby -v or ruby200 -v the VM put its hands in the air and went silent.
You need to enable ROR Software Collections specifically for the task. Please see https://wiki.contribs.org/Software_Collections:Nodejs#Enable_the_Node.js_environment_at_boot_time as an example
HTH
-
edit - OK, sort of have it running. Have tried with both ruby193 and ruby200, I can get the version up with >scl enable ruby200 'ruby -v' but when I go to install rails using gem it complains I don't have ruby-2.2.2 now.
Last error message is 'activsupport requires Ruby version >= 2.2.2.
Thoughts?
Is there some documentation I have been unable to find on the site that I am missing?
Yeah, if there is a dependency for a higher version of ROR other then available via SCL, then you are out of luck for now...
-
Its strange, I did a search for ruby on rails in wiki, forums, howto etc, but the software collections item did not show.
I know.. the internal search engine in the wiki is not the best..
-
also tried installing rh-ruby22 from scl and tried to install rails on it. I can do it for an older version of rails, but that will just give me more headaches down the road.
I might try with the latest Koozali 10 iteration and see how that goes.
I will let you know how I go
-
I'll spin up a VM and see how I go. Will let you know.