|
Cap 2.1, Rails 1.2.5, rake task, and Dreamhost problem...: msg#00169lang.ruby.capistrano.general
I am experiencing a Catch-22 problem: - Deploying a simple rails 1.2.5 app on a Dreamhost account. - Dreamhost only has Rails 1.2.3 installed, so I've installed my own Ruby, rubygems, Rails, etc., which is working *almost* perfectly. (The exception is the problem I am describing here.) - There is an :after_update_code task that calls a rake task to deploy a tagged version of Rails to a shared location (patterned after Mike Clark's "Managing Rails Versions with Capistrano" and Matthew Bass's "Converting Mike's Capistrano Cadillac into a Camero" blog posts, and my own improvements (http://pastie.caboo.se/116805). The task is running this: cd #{release_path} && rake deploy_edge #{rails_version} SHARED_PATH=#{deploy_to}/shared deploy_edge is in the pastie, above, and works locally on my Mac and when executed from the shell on the host. - The rake task is failing with the following error: * executing "cd /home/me/blah.org/releases/20071126062713 && rake deploy_edge TAG=rel_1-2-5 SHARED_PATH=/home/me/blah.org/shared" servers: ["blah.org"] [blah.org] executing command *** [err :: blah.org] /usr/bin/rake:17:Warning: require_gem is obsolete. Use gem instead. *** [err :: blah.org] Cannot find gem for Rails =1.2.5.0: *** [err :: blah.org] Install the missing gem with 'gem install - v=1.2.5 rails', or *** [err :: blah.org] change environment.rb to define RAILS_GEM_VERSION with your desired version. - When I run "rake deploy_edge TAG=rel_1-2-5 SHARED_PATH=/home/me/ blah.org/shared" from the host shell, it works perfectly, but it's using the rake that I installed, which is using the Rails 1.2.5 that is in my own gems directory. From the error above, Dreamhost's rake is being run (/usr/bin/rake) against Dreamhost's gems, which don't include Rails 1.2.5. - My .bash_profile in my shell is what puts my own bin directory in front of Dreamhost's, which is how my Ruby/gem/rake/Rails gets found when I run from the shell. However, Capistrano doesn't appear to be using my .bash_profile to set the PATH. Question: what do I need to do to set the PATH s.t. Capistrano shell commands find my private Ruby/gem/rake/Rails? Thank you in advance. Ed |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: Capistrano 2.0.0 => 2.1.0 no prompt for SSH password, non-root user can't run "cap" at all: 00169, VPC |
|---|---|
| Next by Date: | Capistrano rails app deployment without DB: 00169, MrBanabas-gM/Ye1E23mwN+BqQ9rBEUg@xxxxxxxxxxxxxxxx |
| Previous by Thread: | =?x-unknown?b?W0NhcGlzdHJhbm9dICgpKCgpKCkoKSoqKioqKSopKikqKikqKSkq?==?x-unknown?b?KikqKSopKikqKSogICAgICAgICAgICAgICAgICAgICAgICAgIA==?=i: 00169, gh |
| Next by Thread: | Re: Cap 2.1, Rails 1.2.5, rake task, and Dreamhost problem...: 00169, ed_ruder |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |