RVM and Jenkins setup
try:
. $(/home/RVM_USER/.rvm/bin/rvm env 1.9.3@rails-3.2.3 --path)
make sure you run the stable RVM:
rvm get stable
NOTE:
Last Jenkins version does not always accept "source", but ".".
RVM_USER is the user that installed RVM.
Alternatively you can also export the RVM command in the main PATH.
Jenkins using wrong version of Ruby(rvm)
I ran into this problem too. It turned out that there is an issue if you install rvm as root. We had to fully uninstall rvm and reinstall as the jenkins user, after which the plugin correctly loaded rubies.
You can detect this problem by listing the contents of the directory pointed by Jenkins's $HOME variable. If there is no .rvm directory then you may need to reinstall.
How to set up a CI environment using jenkins, rvm and cucumber
Okay I will try and help you as best I can.
- poll for any changes to github
This can be easily done with the Github Plugin located here
- if there are, run the build script: a. migrate the development and test dbs?(does that mean i have to put the config/database.yml in my
repo?) b. run cucumber c. if all tests pass go to 3, else fail
Then all you would is run the build script you have configure in the in the build from
Select "Add Build Step" -> "Execute shell".
You can either do that which is probably what I would do because when you create build you want them to be portable so you can start up in new jenkins instances, so you dont have to setup your build machine, with build specific files.
Then you run your tests, if they fail the build should fail regardless here is some information on running ruby on rails tests. if you need to manually fail a build in a script based on a result usually exiting a script with non-zero will fail the build. If not continue and run your rake and deployment scripts.
Just a few notes on Jenkins it wont do everything for you but if you can do it manaually Jenkins can automate it. So anything you have setup running manually with a little bit of effort you can get up and running automated with Jenkins
Here is another answer you might find helpful in your general setup and ideology behind Jenkins.
Goodluck!
Related Topics
Create Custom HTML Helpers in Ruby on Rails
Why Doesn't Ruby Have a Real Stringbuffer or Stringio
Rails: How to Get Has_Many Associations of a Model
Calling Sinatra from Within Sinatra
How to Validate Xhtml with Nokogiri
Replace "&" to "\&" in Ruby Seems Impossible
Bundle Install Issue with Libv8 and Rails
Ruby, !! Operator (A/K/A the Double-Bang)
Switch Theme in an Existing Jekyll Installation
How to Calculate How Many Years Passed Since a Given Date in Ruby
Disable Sprockets Asset Caching in Development
Rvm Does Not Install Ruby 1.9.2 on Snow Leopard: 'Error Running 'Make '
Rails Active Admin CSS Conflicting with Twitter Bootstrap CSS