[deploy] config

This commit is contained in:
2018-01-01 20:42:55 +03:00
parent f1156d0779
commit 7209a297d7
4 changed files with 34 additions and 4 deletions

16
config/config.rb Normal file
View File

@@ -0,0 +1,16 @@
set :config_role, :app
set :config_path, -> { release_path }
set :config_type, 'json'
namespace :config do
task :setup do
config_role = fetch(:config_role)
config_path = fetch(:config_path)
config_type = fetch(:config_type)
on roles(config_role) do |server|
# stage = fetch(:stage)
execute "cd #{config_path} && cp config.#{server.hostname}.#{config_type} config.#{config_type}"
end
end
end