diff --git a/config/deploy/production-ci.rb b/config/deploy/production-ci.rb index 0ee12b8..28672b6 100644 --- a/config/deploy/production-ci.rb +++ b/config/deploy/production-ci.rb @@ -1,11 +1,13 @@ set :rails_env, :production server 'webdns4.grnet.gr', user: 'deployer', roles: %w(web app db) +set :branch, ENV['BRANCH'] if ENV['BRANCH'] + set :ssh_options, forward_agent: false, port: 29 #Override commands with sudo, for use with jenkins deployer #SSHKit.config.command_map = Hash.new do |hash, command| # hash[command] = "sudo -u webdns #{command}" #end diff --git a/config/deploy/staging-ci.rb b/config/deploy/staging-ci.rb index 1dfc2ab..5f43a5b 100644 --- a/config/deploy/staging-ci.rb +++ b/config/deploy/staging-ci.rb @@ -1,5 +1,7 @@ set :rails_env, :production server 'webdns4.staging.grnet.gr', user: 'deployer', roles: %w(web app db) +set :branch, ENV['BRANCH'] if ENV['BRANCH'] + set :ssh_options, forward_agent: false, port: 29 diff --git a/config/deploy/test.rb b/config/deploy/test.rb index bdc7820..e2a3972 100644 --- a/config/deploy/test.rb +++ b/config/deploy/test.rb @@ -1,11 +1,13 @@ set :rails_env, :production server 'webdns4.test.grnet.gr', user: 'deployer', roles: %w(web app db) +set :branch, ENV['BRANCH'] if ENV['BRANCH'] + set :ssh_options, forward_agent: false, port: 29 #Override commands with sudo, for use with jenkins deployer SSHKit.config.command_map = Hash.new do |hash, command| hash[command] = "sudo -u webdns #{command}" end