put() and upload() fail

10 views
Skip to first unread message

Kyle Bragger

unread,
Jan 4, 2010, 2:50:29 PM1/4/10
to Capistrano
Cross-posted on Stackoverflow:
http://stackoverflow.com/questions/2001730/capistrano-put-and-upload-both-failing

With capistrano, I am deploying a Rails application from Mac OS X 10.5
to CentOS 5.2

There is a task within our deploy.rb file called `upload`:

put(File.read( file ),"#{shared_path}/#{filename}", :via => :scp)

This fails each and every time with the following exception:

No such file or directory - /srv/ourapp/releases/20100104194410/
config/database.yml

My local copy of config/database.yml is failing to upload properly.
I've verified it's not our internet connection, as this happens on
three different connections and two different systems.

I've also tried to swap out put() for upload() but get the same
result; also, dropping :via => :scp, and/or trying to force :sftp
instead similarly fails.


Relevant info:

$ cap -V
Capistrano v2.5.10

$ ruby -v
ruby 1.8.7 (2008-08-11 patchlevel 72) [i686-darwin9.6.0]

Lee Hambley

unread,
Jan 4, 2010, 3:18:03 PM1/4/10
to capis...@googlegroups.com
Does 20100104194410 represent the latest release, or the current time you're running the task that uploads (and is the task being run as part of a deploy, or standalone?

-- Lee Hambley

Twitter: @leehambley | @capistranorb

Kyle Bragger

unread,
Jan 4, 2010, 3:19:41 PM1/4/10
to Capistrano
The current release.

Kyle Bragger

unread,
Jan 4, 2010, 4:38:22 PM1/4/10
to Capistrano
So I got it working - it was trying to symlink the shared resource
into an old release directory. However, now capistrano is actually
deleting the latest release directory right after symlinking it.

Any ideas?

Lee Hambley

unread,
Jan 5, 2010, 2:00:13 PM1/5/10
to capis...@googlegroups.com
Kyle, Fixed in 2.5.12 (my mistake) – released just a few minutes ago
Reply all
Reply to author
Forward
0 new messages