Error when deploying: cap deploy using cp -R instead of svn

97 views
Skip to first unread message

noinar...@gmail.com

unread,
Dec 16, 2013, 8:29:03 AM12/16/13
to capis...@googlegroups.com
Hello Guys,

I've an error when trying to deploy with Capistrano, when i run cap deploy it tries to do a cp -R instead of calling svn, i've run a cap deploy:check and everything seems fine (output below).

Any help or hint appreciated as i've been googling this group and reading the docs but cannot find why this happens ;-)

Thank by advance,

N.

Versions:
  • Ruby 1.9.2p290
  • Rails 3.1
  • Capistrano v2.14.1
  • Rvm 1.17.7
  • Subversion 1.6.6
Platform:
  • Working on OSX Mountain Lion
  • Deploying to Ubuntu Linux
Logs:
  • Here is the log of cap deploy:check
cap deploy:check
 
* 2013-12-16 14:22:50 executing `deploy:check'
  * executing "test -d /var/www/vhosts/myapp.com.au/rails_app/releases"
    servers: ["11.11.11.11"]
    [11.11.11.11] executing command
    command finished in 1810ms
  * executing "test -w /var/www/vhosts/myapp.com.au/rails_app"
    servers: ["11.11.11.11"]
    [11.11.11.11] executing command
    command finished in 1435ms
  * executing "test -w /var/www/vhosts/myapp.com.au/rails_app/releases"
    servers: ["11.11.11.11"]
    [11.11.11.11] executing command
    command finished in 1739ms
  * executing "which /usr/bin/svn"
    servers: ["11.11.11.11"]
    [11.11.11.11] executing command
    command finished in 1433ms
You appear to have all necessary dependencies installed

  • Here is the log of cap deploy
cap deploy
 
* 2013-12-16 14:10:17 executing `deploy'
  * 2013-12-16 14:10:17 executing `
deploy:update'
 ** transaction: start
  * 2013-12-16 14:10:17 executing `deploy:update_code'

 
* executing "cp -R https://svn.example.com/private/myapp/trunk /var/www/vhosts/myapp.com.au/rails_app/releases/20131216131017 && (echo  > /var/www/vhosts/myapp.com.au/rails_app/releases/20131216131017/REVISION)"
    servers
: ["11.11.11.11"]
   
[11.11.11.11] executing command
 
** [out] cp: impossible d'évaluer «https://svn.example.com/private/myapp/trunk»: Aucun fichier ou dossier de ce type
    command finished in 1406ms
*** [deploy:update_code] rolling back
  * executing "rm -rf /var/www/vhosts/myapp.com.au/rails_app/releases/20131216131017; true"
    servers: ["11.11.11.11"]
    [11.11.11.11] executing command
    command finished in 1431ms
failed: "rvm_path=/usr/local/rvm /usr/local/rvm/bin/rvm-shell '
ruby-1.9.2-p290@myapp_rails31' -c 'cp -R https://svn.example.com/private/myapp/trunk /var/www/vhosts/myapp.com.au/rails_app/releases/20131216131017 && (echo  > /var/www/vhosts/myapp.com.au/rails_app/releases/20131216131017/REVISION)'" on 11.11.11.11

Lee Hambley

unread,
Dec 16, 2013, 9:08:38 AM12/16/13
to capistrano
Please post your configuration.

--
You received this message because you are subscribed to the Google Groups "Capistrano" group.
To unsubscribe from this group and stop receiving emails from it, send an email to capistrano+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/capistrano/4e6d3b65-6d17-4ae3-a8bc-2c694f56c555%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

noinar...@gmail.com

unread,
Dec 16, 2013, 9:24:33 AM12/16/13
to capis...@googlegroups.com
Thanks for your quick answer Lee,

Here is my config/deploy.rb

Best regards,

N.

require 'bundler/capistrano'
require "delayed/recipes"

set :rails_env, "production"


default_run_options
[:pty] = true
set :use_sudo, false


set :user, "myapp" # Linux user
set :application, "myapp"
set :repository,  "https://svn.example.com/private/myapp/trunk"


set :deploy_to, "/var/www/vhosts/myapp.com.au/rails_app"
set :port, "1305"
set :domain, "11.11.11.11"

role
:app, domain
role
:web, domain
role
:db,  domain, :primary => true


set :keep_releases, 4


require "rvm/capistrano" # Load RVM's capistrano plugin.
set :rvm_ruby_string, 'ruby-1.9.2-p290@myapp_rails31'
set :rvm_type, :system


# -- Bundler
# *** Must be defined after :deploy_to and :application
set :bundle_without, [:development, :test, :darwin]
set :bundle_dir, File.join(fetch(:shared_path), 'vendor', 'bundle')
set :bundle_flags,    "--deployment --quiet"

set :scm_command, "/usr/bin/svn"
set :local_scm_command, :default
set :scm_username, 'deploy_myapp'
set :scm_password, proc{Capistrano::CLI.password_prompt("SVN password for #{scm_username}:")}


 

noinar...@gmail.com

unread,
Dec 16, 2013, 9:32:28 AM12/16/13
to capis...@googlegroups.com
Ok it works now if i force the :scm variable:

set :scm, :subversion


Never had to do that before though..

Best regards,

N

Lee Hambley

unread,
Dec 16, 2013, 9:33:24 AM12/16/13
to capistrano
Great, I'm happy that it works!

--
You received this message because you are subscribed to the Google Groups "Capistrano" group.
To unsubscribe from this group and stop receiving emails from it, send an email to capistrano+...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages