I have a Ruby On Rails Application that has been going for about 9 months. The Production environment is a Ubuntu Server using Apache and Passenger.
I deploy using Capistrano and this has been working fine using my Git repository.
I have just changed development machines and now when I try to deploy I get a timeout error. I’m not sure where the error is but I have a feeling it might be some kind of security.
My development machine is a ubuntu 12.04 desktop. The terminal output from the ‘cap deploy’ is as follows:
* executing `deploy`
* executing `deploy:update`
** transaction: start
* executing `deploy:update_code`
updating the cached checkout on all servers
executing locally: "git ls-remote git@github.com:nicko777/Tata.git HEAD"
command finished in 4260ms
* executing "if [ -d /home/passenger/Tata/shared/cached-copy ]; then cd /home/passenger/Tata/shared/cached-copy && git fetch -q origin && git fetch --tags -q origin && git reset -q --hard 34350075132fff5c0bd8a831667680f6c912ef23 && git clean -q -d -x -f; else git clone -q git@github.com:nicko777/Tata.git /home/passenger/Tata/shared/cached-copy && cd /home/passenger/Tata/shared/cached-copy && git checkout -q -b deploy 34350075132fff5c0bd8a831667680f6c912ef23; fi"
servers: ["10.1.1.21"]
Password:
[10.1.1.21] executing command
** [10.1.1.21 :: out] Write failed: Broken pipe
** fatal: The remote end hung up unexpectedly
command finished in 1033137ms
*** [deploy:update_code] rolling back
* executing "rm -rf /home/passenger/Tata/releases/20120626103643; true"
servers: ["10.1.1.21"]
[10.1.1.21] executing command
command finished in 16ms
failed: "sh -c 'if [ -d /home/passenger/Tata/shared/cached-copy ]; then cd /home/passenger/Tata/shared/cached-copy && git fetch -q origin && git fetch --tags -q origin && git reset -q --hard 34350075132fff5c0bd8a831667680f6c912ef23 && git clean -q -d -x -f; else git clone -q git@github.com:nicko777/Tata.git /home/passenger/Tata/shared/cached-copy && cd /home/passenger/Tata/shared/cached-copy && git checkout -q -b deploy 34350075132fff5c0bd8a831667680f6c912ef23; fi'" on 10.1.1.21
Worked out what was wrong with this. When I created the new machine it upgraded Capistrano to version 2.12.0, I checked on the server and this had version 2.9.0.
I downgraded the version on my new machine to 2.9.0 and the cap deploy works fine now.