Hi,
Thank you for a fast responxe that helped until I ran cap deploy. When deploying now the app stops responding and I get:
= = = = = = = = = =
Macintosh-3:applabDK bovittrup$ cap deploy
* executing `deploy'
* executing `deploy:update'
** transaction: start
* executing `deploy:update_code'
applabd@applab.dk's password:
Connection closed by 208.101.17.116
svn: Connection closed unexpectedly
*** [deploy:update_code] rolling back
* executing "rm -rf /home/applabd/apps/applabDK/releases/20080621071950; true"
servers: ["applab.dk"]
Password:
[applab.dk] executing command
command finished
/usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy/scm/subversion.rb:58:in `query_revision': tried to run `svn info svn+ssh://applabd@applab.dk/home/applabd/svn/applabDK/trunk -rHEAD' and got unexpected result "" (RuntimeError)
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy/scm/base.rb:35:in `send'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy/scm/base.rb:35:in `method_missing'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy/scm/base.rb:63:in `local'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy/scm/base.rb:35:in `method_missing'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/recipes/deploy.rb:37:in `load'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/configuration/variables.rb:87:in `call'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/configuration/variables.rb:87:in `fetch'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/configuration/variables.rb:110:in `protect'
... 35 levels...
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/lib/capistrano/cli/execute.rb:14:in `execute'
from /usr/local/lib/ruby/gems/1.8/gems/capistrano-2.3.0/bin/cap:4
from /usr/local/bin/cap:19:in `load'
from /usr/local/bin/cap:19
= = = = = = = = = =
My deploy.rb file looks as follows:
= = = = = = = = = =
# =============================================================================
# REQUIRED VARIABLES
# =============================================================================
# User specific variables
set :domain, "applab.dk"
set :user, "applabd"
set :application, "applabDK"
# set :mongrel_port, "****"
# set :mongrel_nodes, "*"
set :rails_env, :production
set :deploy_to, "/home/#{user}/apps/#{application}"
set :chmod755, %w(app config db lib public vendor script tmp public/dispatch.cgi public/dispatch.fcgi public/dispatch.rb)
set :use_sudo, false
set :repository, "svn+ssh://#{user}@#{domain}/home/#{user}/svn/#{application}/trunk"
# set :repository, "http://svn.#{domain}/svn/#{application}/trunk"
# Won't work on windows otherwise, see
#
http://groups.google.com/group/capistrano/browse_thread/thread/13b029f75b61c09ddefault_run_options[:pty] = true
# =============================================================================
# ROLES
# =============================================================================
role :web, domain
role :app, domain
role :db, domain, :primary => true
# =============================================================================
# SSH OPTIONS
# =============================================================================
# ssh_options[:keys] = %w(/full/path/to/your/ssh_key/id_rsa)
# =============================================================================
# FCGI TASKS
# =============================================================================
# Uncomment these tasks if using FCGI to serve your Rails Application
desc "FCGI is already running, so we don't really need the spinner script, but we have it create the initial symlink for us"
task :spinner, :roles => :app do
run "rm -rf /home/#{user}/public_html;ln -s #{current_path}/public /home/#{user}/public_html"
end
desc "Restart the FCGI Process"
task :restart, :roles => :app do
run "cd #{current_path}; killall dispatch.fcgi"
cleanup
end
# =============================================================================
# TASKS
# =============================================================================
desc "Set the proper permissions for directories and files on HostingRails accounts"
task :after_deploy do
run(chmod755.collect do |item|
"chmod 755 #{current_path}/#{item}"
end.join(" && "))
end
= = = = = = = = =
Br Bo