So, if you've got some stuff set in your .bashrc files that are expecting to be loaded, that's probably why.
- Jamis On Sep 3, 2008, at 10:26 AM, robert.najlis wrote:
I got capistrano up to 2.5 (I really should have checked on that earlier). I got the error on running saying that the chronic gem was not found, however, on running the rake task from the command line (in the correct current_path directory) it did work just fine. Is there something in the startup of capistrano that does not load my full environment? Or could it somehow load a different environment? I'm not sure why the chronic gem would not be found when running via capistrano, but it is found from the command line. By the way, I am using Mac OS X 10.5, not sure if that makes any difference. I am testing the deploy on my local machine before putting it on the production server (which is redhat linux). here is the error message I received: * executing "cd /data/web/current && sudo -p 'sudo password: ' rake ultrasphinx:daemon:start RAILS_ENV=production" servers: ["localhost"] [localhost] executing command *** [err :: localhost] rake aborted! *** [err :: localhost] no such file to load -- chronic *** [err :: localhost] *** [err :: localhost] (See full trace by running task with --trace) ** [out :: localhost] (in /data/web/releases/20080903161844) ** [out :: localhost] sudo gem install rcov # if you want the rcov tasks command finished failed: "sh -c \"cd /data/web/current && sudo -p 'sudo password: ' rake ultrasphinx:daemon:start RAILS_ENV=production\"" on localhost thanks a lot for your help! ;Robert On Sep 3, 11:58 am, Jamis Buck <[EMAIL PROTECTED]> wrote:What version of Capistrano are you using? The inline sudo won't work prior to cap 2.4. - Jamis On Sep 3, 2008, at 9:43 AM, robert.najlis wrote:Thanks a lot for the reply. Unfortunately this did not quite do thetrick. I got a 0 for 1 args error for sudo. So I tried it this way:run "cd #{current_path} && #{sudo('ultrasphinx:daemon:stop rake RAILS_ENV=production')}"but the I got the no rakefile found problem again...trying it then just with the run command, and running as root, I got aproblem saying that a gem required (for running ultrasphinx -- chronic) was not found. So that makes me think that maybe theenvironment is not being set up correctly, or that something differentis happening in the ruby environment for capsitrano that I am not aware of.Is there something I am missing? Maybe in the setup of capistrano?Thanks a lot.RobertOn Sep 2, 9:42 pm, Jamis Buck <[EMAIL PROTECTED]> wrote:Try this:run "cd #{current_path} && #{sudo} rake RAILS_ENV=production ultrasphinx:daemon:stop"Doing it as a sudo() call results in the following command:sudo cd #{current_path} && rake ...Which does the cd as sudo, and the rake as not-sudo...- JamisOn Sep 2, 2008, at 5:01 PM, robert.najlis wrote:Sorry if this is an old issue, but I have been searching, and have been unable to find an answer for this.I am trying to call a rake task from my capistrano scriptThe command I am using is sudo "cd #{current_path} && RAILS_ENV=production rake ultrasphinx:daemon:stop"However, I get the following error:[out :: localhost] rake aborted! ** [out :: localhost] No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb) ** [out :: localhost] /Library/Ruby/Gems/1.8/gems/rake-0.8.1/lib/ rake.rb:2143:in `raw_load_rakefile'** [out :: localhost] (See full trace by running task with -- trace)command finishedI have tried doing things in the deploy.rb file such as setting therake file with comands likeset :rake, "rake -f rails/Rakefile"but to no availIf anyone has any ideas I would be most appreciativeThanks a lot.Robertsmime.p7s 3KViewDownloadsmime.p7s 3KViewDownload--~--~---------~--~----~------------~-------~--~----~ To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/capistrano -~----------~----~----~----~------~----~------~--~---
smime.p7s
Description: S/MIME cryptographic signature