0.0
No commit activity in last 3 years
No release in over 3 years
Confirm before deploy in Capistrano
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 2.13
 Project Readme

ConfirmDeploy

Simple capistrano recipe to get user(s) to confirm before deploying an app.

Installation

Add this line to your application's Gemfile:

gem 'confirm_deploy'

And then execute:

$ bundle

Or install it yourself as:

$ gem install confirm_deploy

Usage

Add to your capistrano deploy.rb

require 'confirm_deploy'

Customize

You can set the optional variables confirm_message and confirm_answer if you want:

set :confirm_message, "You know what you're doing?"
set :confirm_answer, "yepp"

Examples

Confirmed deploy:

$ cap deploy
  * 2012-12-15 14:52:11 executing `deploy'
  * 2012-12-15 14:52:11 executing `deploy:update'
 ** transaction: start
  * 2012-12-15 14:52:11 executing `deploy:update_code'
    triggering before callbacks for `deploy:update_code'
  * 2012-12-15 14:52:11 executing `deploy:confirm'
 ** Deploying...
  Are you sure you want to deploy? (yes): yes
...

Unconfirmed deploy:

$ cap deploy
  * 2012-12-15 14:52:11 executing `deploy'
  * 2012-12-15 14:52:11 executing `deploy:update'
 ** transaction: start
  * 2012-12-15 14:52:11 executing `deploy:update_code'
    triggering before callbacks for `deploy:update_code'
  * 2012-12-15 14:52:11 executing `deploy:confirm'
 ** Deploying...
  Are you sure you want to deploy? (yes): no
*** Deploy cancelled!

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request