Switchtower deploy fails though setup works


#1

I’m trying to use SwitchTower to deploy from XP to Dreamhost. Based on
http://nubyonrails.com/pages/shovel_dreamhost, my deploy.rb looks
like:

set :user, ‘dankohn’
set :application, “flydash.com
set :repository, “http://svn.flydash.com/flydash/flydash
#set :repository, “svn+ssh://home/#{user}/svn/flydash”
#set :repository, “file:///home/#{user}/svn/flydash”
set :checkout, “export”
role :app, application
role :db, application, :primary => true
set :deploy_to, “/home/#{user}/#{application}”

Whatever, I use for the repository, I consistently get the error:

C:\Dan\dev\radrails\flydash>rake --trace deploy
(in C:/Dan/dev/radrails/flydash)
** Invoke deploy (first_time)
** Execute deploy
loading configuration c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0
.10.0/lib/switchtower/recipes/standard.rb
loading configuration ./config/deploy.rb
executing task deploy
transaction: start
executing task update_code
querying latest revision…
c:/Program Files/Ruby/bin/rake.bat: No such file or directory - svn log
-q -rhea
d file:///home/dankohn/svn/flydash
[update_code] transaction: rollback
[update_code] rolling back
executing “rm -rf /home/dankohn/flydash.com/releases/20060210190727”
servers: [“flydash.com”]
Password: ********
processing command
[flydash.com] executing command
command finished
rake aborted!
private method scan' called for nil:NilClass c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ scm/subversion.rb:26:inlatest_revision’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
configuration.rb:58:in initialize' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ configuration.rb:74:in[]’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
configuration.rb:195:in method_missing' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ scm/subversion.rb:71:incheckout’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
recipes/standard.rb:67:in load' recipes/standard.rb:67:inload’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
actor.rb:114:in update_code' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ recipes/standard.rb:138:inload’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
actor.rb:296:in transaction' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ recipes/standard.rb:137:inload’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
actor.rb:114:in deploy' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ cli.rb:242:inexecute_recipes!’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/
cli.rb:242:in execute_recipes!' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/switchtower-0.10.0/lib/switchtower/ cli.rb:217:inexecute!’
./lib/tasks/switchtower.rake:17:in switchtower_invoke' ./lib/tasks/switchtower.rake:22 c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:232:inexec
ute’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:232:in exec ute' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:202:ininvo
ke’
c:/Program Files/Ruby/lib/ruby/1.8/thread.rb:135:in synchronize' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:195:ininvo
ke’
c:/Program
Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:1719:in run ' c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/lib/rake.rb:1719:inrun

c:/Program Files/Ruby/lib/ruby/gems/1.8/gems/rake-0.7.0/bin/rake:7
c:/Program Files/Ruby/bin/rake.bat:25

C:\Dan\dev\radrails\flydash>

By contrast, “rake remote_exec ACTION=setup” works perfectly and after
prompting
for the password, successfully creates the directories on the server.

Why is SwitchTower looking for rake.bat? What do I have misconfigured?
Thanks
in advance for your help.


#2

ST isn’t looking for rake.bat - rake.bat is looking for svn. Make
sure that svn is in your path.

Pat