Matthew O''Riordan
2010-Oct-15 16:36 UTC
[Cruisecontrolrb-users] CruiseControl.rb with RVM & Bundler
Hi all I''ve recently installed CruiseControl.rb and have a variety of Ruby & Rails projects which I am looking to use CC with. Unfortunately the projects use a variety of gem bundles, and even worse, different version of Ruby. As such, I really need to get RVM and ideally bundler working with CruiseControl. Has anyone made any progress with this? I''ve done some searching, and can''t seem to find anyone who has as yet got it working. Any advice and pointers in the right direction would be appreciated. Matt BTW. I realise there is a post at http://groups.google.com/group/cruisecontrolrb-rubyforge-mailing-list/browse_thread/thread/81892db289a9a360 and I have tried to post to this, but unfortunately my posts have disappeared. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20101015/b4c2f95f/attachment.html>
Todd Sedano
2010-Oct-15 17:04 UTC
[Cruisecontrolrb-users] CruiseControl.rb with RVM & Bundler
Matt, I recently went through the pain of trying to get CruiseControl to work with rvm and bundler. I''m not a build expert and would rather spend my time writing code. Unfortunately, the cruise control documentation has not been updated to reflect these new technologies. I teach a course where we have 25 student teams using a build machine and next year we will be switching to a different product. Cruise Control and bundler --- Chad Woolley and I had an email thread on the group about a month ago, please check it out. (Bundler and cruise control.rb 6/17/10, 7/14, 9/24) He had some very good suggestions, but I needed a little more explicit guidance. In the end, for me to get bundler to work with cruise control, this is what I did: a) modify .cruise/projects/NAME/cruise_config.rb to execute a shell command. In this case, I choose project.build_command = ''../build_my_app.sh'' because my build scripts were not in source control. Since I was working with student teams, I wanted them all on the build machine. Perhaps next time I would put them in source control. b) create build_my_app.sh bundle install ruby -e "require ''rubygems'' rescue nil; require ''rake''; load ''/Users/tsedano/cruisecontrol-1.4.0/tasks/cc_build.rake''; ARGV << ''--nosearch'' << ''cc:build''; Rake.application.run; ARGV.clear" The first line runs bundle install as the cruise control unix user, the second line is the line that my cruise control normally executes; I got it from the build logs I tried several variants to get bundler to work from lib/tasks/cruise.rake but was not successful. When cruise.rake executes it needs to have the rails environment ready, but it wasn''t since bundle hadn''t been run yet. I''m sure there is a better way to do this, but I wasn''t able to get it to work. Cruise Control and rvm --- As the command prompt, I was using bundler 1.0.2, but when cruise control was running, it was using bundler 0.9.6 for some projects -- I couldn''t find how and where it was getting the wrong bundler from my filesystem. In the end, I disabled rvm, found the 0.9.6 gem, and then was able to uninstall it. I suspect that cruise control is running as a different user on my system. I decided not to reinstall rvm. I briefly was considering switching to Hudson or Team City. While I was looking at those products, I came across this thread. If I had more time, I would try out some of the commands in their shell script to see if it would get Cruise Control to work well with rvm. http://groups.google.com/group/rubyversionmanager/browse_thread/thread/d2271d37ad7f844f If you are able to get this to work, please post back to the group. Also, please try and find the cruise control website maintainers and get the official documentation updated. I would do that, but I''m not convinced this is the "right" way to solve the problem. Todd On Fri, Oct 15, 2010 at 9:36 AM, Matthew O''Riordan < matthew.oriordan at gmail.com> wrote:> Hi all > > I''ve recently installed CruiseControl.rb and have a variety of Ruby & Rails > projects which I am looking to use CC with. Unfortunately the projects use > a variety of gem bundles, and even worse, different version of Ruby. As > such, I really need to get RVM and ideally bundler working with > CruiseControl. > > Has anyone made any progress with this? I''ve done some searching, and > can''t seem to find anyone who has as yet got it working. > > Any advice and pointers in the right direction would be appreciated. > > Matt > > BTW. I realise there is a post at > http://groups.google.com/group/cruisecontrolrb-rubyforge-mailing-list/browse_thread/thread/81892db289a9a360 and > I have tried to post to this, but unfortunately my posts have disappeared. > > _______________________________________________ > Cruisecontrolrb-users mailing list > Cruisecontrolrb-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/cruisecontrolrb-users > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20101015/a910babd/attachment.html>
Todd Sedano
2010-Nov-05 04:11 UTC
[Cruisecontrolrb-users] CruiseControl.rb with RVM & Bundler
Matthew, I was curious what your final experience was like with CruiseControl, rvm, and bundler and if you found any good solutions to the questions you were asking? Todd -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20101104/0ee3f111/attachment.html>
Matthew O''Riordan
2010-Nov-05 11:40 UTC
[Cruisecontrolrb-users] CruiseControl.rb with RVM & Bundler
I didn''t get a response from anyone unfortunately so didn''t get very far... On 5 Nov 2010, at 04:11, Todd Sedano wrote:> Matthew, > > I was curious what your final experience was like with CruiseControl, rvm, and bundler and if you found any good solutions to the questions you were asking? > > Todd