Files
nairobi/config/deploy.rb
Juanjo Bazán 8a8ca834ba adds capistrano-rvm
sets ruby version for deploy to 2.2.2
2015-08-07 12:21:03 +02:00

39 lines
912 B
Ruby

# config valid only for current version of Capistrano
lock '3.4.0'
def deploysecret(key)
@deploy_secrets_yml ||= YAML.load_file('config/deploy-secrets.yml')[fetch(:stage).to_s]
@deploy_secrets_yml[key.to_s]
end
set :rails_env, fetch(:stage)
set :rvm_ruby_version, '2.2.2'
set :application, 'participacion'
set :repo_url, 'git@github.com:AyuntamientoMadrid/participacion.git'
set :scm, :git
set :revision, `git rev-parse --short #{fetch(:branch)}`.strip
set :log_level, :info
set :linked_files, %w{config/database.yml config/secrets.yml}
set :linked_dirs, %w{log tmp public/system public/assets}
set :keep_releases, 5
set :local_user, ENV['USER']
namespace :deploy do
after :restart, :clear_cache do
on roles(:web), in: :groups, limit: 3, wait: 10 do
# Here we can do anything such as:
# within release_path do
# execute :rake, 'cache:clear'
# end
end
end
end