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
16
votes
3 answers

Capistrano 3 does not restart after deploy

I've recently updated my capistrano gem to version 3.1.0, and since then cap production deploy passes fine, but the target deploy:restart is not called. My server is deployed on Ubuntu 12.10 on Amazon EC2. Why could that be?
Uri Agassi
  • 36,848
  • 14
  • 76
  • 93
15
votes
6 answers

How can I use Rails 5.2 credentials in capistrano's deploy.rb file?

I've just updated my Rails app to 5.2, and configured it to use the new config/credentials.yml.enc file. When I try to deploy, I get this error: NameError: uninitialized constant Rails /Users/me/Documents/project/config/deploy.rb:27:in `
15
votes
2 answers

capistrano 3 set ssh port but 22 is still used

I'm trying to set up access to server via a port (ssh is on port 222), but still although i have in my deploy.rb set :application, 'billing' set :repo_url, 'git@github.com:random/stat.git' set :keep_releases, 5 set :ssh_options, { …
Elmor
  • 4,775
  • 6
  • 38
  • 70
14
votes
3 answers

Capistrano 3 + Sprockets 3 + Rails 4.2.1 won't deploy?

I ran bundle update and updated sprockets to 3.0.0. When I try to deploy via Capistrano 3 I get the following error: INFO [e54ac5ca] Running /usr/bin/env cp /var/www/testapp/releases/20150414002210/public/assets/manifest*…
Tallboy
  • 12,847
  • 13
  • 82
  • 173
14
votes
1 answer

Skip database migration while deploying Rails application using Capistrano 3

When we run cap deploy, it runs all the migrations during deployment. We have to point the application to existing DB and don't want modify existing DB. Can anybody suggest how can we skip the migration step while deploying the application?
Amit Patel
  • 15,609
  • 18
  • 68
  • 106
14
votes
1 answer

'Don't know how to build task' error in Capistrano 3

I'm trying to learn to use Capistrano 3 by following the DOCS and I've written a simple task to test my understanding. The task is created in the default task dir in lib/capistrano/tasks: desc "Check status of web server" task :nginx_status…
kaizenCoder
  • 2,211
  • 6
  • 33
  • 64
13
votes
2 answers

Deploy raise error "Don't know how to build task 'assets:precompile'" (Capistrano)

Does anyone ever got this error after run : cap production deploy I'm Using capistrano : Capistrano Version: 3.6.1 (Rake Version: 11.3.0) Here is the log : (Backtrace restricted to imported tasks) cap aborted! SSHKit::Runner::ExecuteError:…
Khalid
  • 887
  • 2
  • 13
  • 26
13
votes
7 answers

Capistrano: cap aborted! SSHKit::Runner::ExecuteError: Exception while executing on host

I'm trying to deploy code with Capistrano 3 to Ubuntu server from GIT repository, but I'm getting this error. ========================================================================== Here is my Gemfile. gem 'capistrano', '~> 3.1.0' #//Use…
JP.
  • 1,035
  • 2
  • 17
  • 39
13
votes
1 answer

Capistrano log level

I've set my Capistrano configuration's log level to error to prevent verbose output. In deploy.rb I've added set :log_level, :error. This works great. However, when I run commands via execute, it isn't printed as it's being written under the log…
Jey Balachandran
  • 3,585
  • 5
  • 27
  • 36
12
votes
2 answers

How do you deploy to only one server with Capistrano v3?

How do you deploy to only one server with Capistrano v3? All the solutions I found out there deploy to every server, so, I would assume they are for v2. I don't want to deploy a stage, I'm already using multistaging and I want to deploy to only one…
Pablo Fernandez
  • 279,434
  • 135
  • 377
  • 622
12
votes
5 answers

How to run custom rake task via capistrano 3?

which way, i can run rake commands via capistrano on remote server. for example i have a lib/task/reparse.rake with some methods desc "it's take csv file, makes some changes and fill db with this info" task :example1 => :environment do require…
kpblc
  • 903
  • 1
  • 8
  • 24
12
votes
5 answers

Starting or restarting Unicorn with Capistrano 3.x

I'm trying to start or restart Unicorn when I do cap production deploy with Capistrano 3.0.1. I have some examples that I got working with Capistrano 2.x using something like: namespace :unicorn do desc "Start unicorn for this application" …
kaplan
  • 4,109
  • 6
  • 30
  • 35
11
votes
1 answer

Unable to deploy Rails App to DigitalOcean because of unsupported key type

I have configured the droplet in DO and nginx is up and running successfully. I followed the guide on DO on deploying to server via Capistrano. I can ssh into the server without entering my password. But on running bundle exec cap production…
tekina
  • 571
  • 10
  • 21
11
votes
1 answer

capistrano 3 Don't know how to build task 'deploy:updated'

Capistrano fails upon cap staging deploy Don't know how to build task 'deploy:updated' /Users/me/.rvm/gems/ruby-1.9.3-p125@theapp/gems/capistrano-3.1.0/lib/capistrano/dsl/task_enhancements.rb:5:in `before' Capfile requires in order: require…
Jerome
  • 5,583
  • 3
  • 33
  • 76
11
votes
1 answer

How do you access rails_env from the Cap deploy command?

In deploy.rb, I believe that :rails_env is typically set by require 'capistrano/rails' found in your Capfile. I am using rails, but not using the built in asset pipeline and therefore, don't use capistrano/rails and was in the predicament of having…
jearlu
  • 550
  • 4
  • 10
1
2
3
54 55