Questions tagged [capistrano3]

Capistrano is an open source tool for running scripts on multiple servers; its main use is deploying web applications. It automates the process of making a new version of an application available on one or more web servers, including supporting tasks such as changing databases.

Learn more from their website: http://capistranorb.com/

Online Screencasts

825 questions
4
votes
1 answer

Capistrano doesn't obey "within release_path"

I have this task: namespace :custom do desc "create a symlink to db config already on the server" task :symlink_db_config do on roles(:web) do within release_path do execute "pwd" end within release_path do …
Grant Birchmeier
  • 17,809
  • 11
  • 63
  • 98
4
votes
2 answers

After deploy I see standard nginx's "It works!"

I've deployed rails app with Capistrano to VPS, and when I try to access it with "APP_NAME.com", I see standard Nginx's "It works!" page. I've tried to remove index.html file from /var/www folder, now I see folders in it: apps, log and tmp. In…
Peter Tretyakov
  • 3,380
  • 6
  • 38
  • 54
4
votes
1 answer

Capistrano 3 Deploy via a Copy

set :deploy_via, :copy has been removed from Cap 3. In case you have no Internet access on production server you may had have a hard time. There is nice Gem capistrano-scm-copy can copy your folder to production server. But it won't justify which is…
Jack Vo
  • 279
  • 2
  • 10
4
votes
2 answers

Capistrano + Whenever gems - bin/rails: Permission denied

I have a production environment configured that deploys and works as it should. Although I have encountered an ancillary problem that I can't figure out. I am running the Whenever gem to execute a couple of cron jobs, the Whenever gem capistrano…
Asciant
  • 2,130
  • 1
  • 15
  • 26
4
votes
1 answer

Capistrano 3 runs every command twice (new install) - Configuration issue

I just completed my capistrano installation for the first time. Most of everything is left to default settings, I configured my server, its authentification, and the remote folder, as well as the access to my git repository. I use capistrano to…
4
votes
2 answers

Capistrano 3 version of on_rollback?

Upgrading to capistrano 3, the following no longer seems to work: namespace :project do desc "Prevents executing by creating lockfile" task :disable do on roles(:app) do execute "touch /tmp/proj_lockfile" end on_rollback do …
Allyl Isocyanate
  • 13,306
  • 17
  • 79
  • 130
4
votes
3 answers

Capistrano 3, using upload! in a task in lib/capistrano/tasks

I'm using Capistrano 3 and I want to create my own task. So I created a file my_new_thing.rake in lib/capistrano/tasks and I can see the task when I run cap -T. But... some of the methods aren't available. When I try to use upload! I get cap…
John Small
  • 942
  • 2
  • 12
  • 21
4
votes
1 answer

Capistrano: cap aborted! Don't know how to build task 'deploy:setup_config'

I'm deploying a Rails 4.0 app to an ubuntu server using capistrano 3.2.1 but I'm getting the error when I try running capistrano commands. cap aborted! Don't know how to build task 'deploy:setup_config' This are the commands I have tried cap…
nancy
  • 41
  • 1
  • 2
4
votes
2 answers

Capistrano read from .env on deployment server

I am trying to perform a database backup as part of a Capistrano (v3) deployment script (for a NON-Rails app). The script works fine -- if I hard-code database config into it. Now I want to load in the database config from a .env file. On my local…
user3070184
4
votes
1 answer

Capistrano 3 recipe for dynamic_sitemaps

I'm trying to "translate" the Capistrano recipe to deploy dynamic_sitemaps to work with Capistrano 3. The snippet suggested in the readme looks like this: after "deploy:update_code", "sitemaps:create_symlink" namespace :sitemaps do task…
janosrusiczki
  • 1,920
  • 2
  • 20
  • 41
4
votes
1 answer

environment variables with capistrano 3

What is the best way to add environment variables with capistrano 3? I've tried both set :default_env, { 'MAILCHIMP' => 'verylongstring' } and set :default_environment, { 'MAILCHIMP' => 'verylongstring', } but none seemed to do anything…
Rudi
  • 1,577
  • 3
  • 16
  • 42
4
votes
2 answers

Capistrano 3 use login shell

I ve read this nice explanation of login/nonlogin, interactive/noninteractive shells http://capistranorb.com/documentation/faq/why-does-something-work-in-my-ssh-session-but-not-in-capistrano/. But I found nowhere, how to run capistrano 3 in specific…
kasi
  • 955
  • 1
  • 12
  • 21
4
votes
1 answer

Error writing to authentication socket on deploy with capistrano3

When i make a deployment with capistrano 3, i have an error but it's not fatal and finally deployment is successful. My error message is: Error writing to authentication socket This error message was shown 3 times. Like this: DEBUG [ac3445fe]…
RaKoDev
  • 613
  • 2
  • 7
  • 22
4
votes
0 answers

Can I Stream the output with Capistrano 3 while the remote command is still running

I'd like to do the same as I could do with Capistrano2 task :memory do run "free | awk '/^Mem:/{print $4}'" do | channel, stream, data | puts "host: #{channel[:host]} has free memory of #{data.to_i/1024} MB" end end Using…
robkuz
  • 9,488
  • 5
  • 29
  • 50
4
votes
2 answers

Remove hook from flow in Capistrano 3

I want to deploy my PHP application using Capistrano 3. My application uses Symfony 2 as a framework and Phing as a built system. I have installed capistrano-symfony so I can use Symfony commands from inside Capistrano. The problem is that it also…
Sander Marechal
  • 22,978
  • 13
  • 65
  • 96