Merge pull request #385 from sgmap/delete-staging
[Fix #77] Kill staging
This commit is contained in:
commit
c789b85a2d
2 changed files with 5 additions and 12 deletions
|
@ -64,7 +64,7 @@ jobs:
|
||||||
- "0a:67:42:7d:7e:b7:e1:3c:48:8f:bf:68:10:51:a8:44"
|
- "0a:67:42:7d:7e:b7:e1:3c:48:8f:bf:68:10:51:a8:44"
|
||||||
- deploy:
|
- deploy:
|
||||||
command: |
|
command: |
|
||||||
if [ "${CIRCLE_BRANCH}" == "staging" ]; then
|
if [ "${CIRCLE_BRANCH}" == "develop" ]; then
|
||||||
bundle exec rake deploy_ha
|
bundle exec rake deploy_ha
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,6 @@ raise "Bad to=#{+ENV['to']}" unless ["staging", "production"].include?(ENV['to']
|
||||||
|
|
||||||
raise "missing domain, run with 'rake deploy domain=37.187.154.237'" if ENV['domain'].nil?
|
raise "missing domain, run with 'rake deploy domain=37.187.154.237'" if ENV['domain'].nil?
|
||||||
|
|
||||||
print "Deploy to #{ENV['to']} environment branch #{branch}\n"
|
|
||||||
|
|
||||||
# set :domain, '5.135.190.60'
|
# set :domain, '5.135.190.60'
|
||||||
set :domain, ENV['domain']
|
set :domain, ENV['domain']
|
||||||
|
@ -26,25 +25,19 @@ set :deploy_to, '/var/www/tps_dev'
|
||||||
|
|
||||||
case ENV["to"]
|
case ENV["to"]
|
||||||
when "staging"
|
when "staging"
|
||||||
if ENV['branch'].nil?
|
set :branch, ENV['branch'] || 'develop'
|
||||||
set :branch, 'staging'
|
|
||||||
else
|
|
||||||
set :branch, ENV['branch']
|
|
||||||
end
|
|
||||||
set :deploy_to, '/var/www/tps_dev'
|
set :deploy_to, '/var/www/tps_dev'
|
||||||
set :user, 'tps_dev' # Username in the server to SSH to.
|
set :user, 'tps_dev' # Username in the server to SSH to.
|
||||||
appname = 'tps_dev'
|
appname = 'tps_dev'
|
||||||
when "production"
|
when "production"
|
||||||
if ENV['branch'].nil?
|
set :branch, ENV['branch'] || 'master'
|
||||||
set :branch, 'master'
|
|
||||||
else
|
|
||||||
set :branch, ENV['branch']
|
|
||||||
end
|
|
||||||
set :deploy_to, '/var/www/tps'
|
set :deploy_to, '/var/www/tps'
|
||||||
set :user, 'tps' # Username in the server to SSH to.
|
set :user, 'tps' # Username in the server to SSH to.
|
||||||
appname = 'tps'
|
appname = 'tps'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
print "Deploy to #{ENV['to']} environment branch #{branch}\n"
|
||||||
|
|
||||||
set :rails_env, ENV["to"]
|
set :rails_env, ENV["to"]
|
||||||
|
|
||||||
# For system-wide RVM install.
|
# For system-wide RVM install.
|
||||||
|
|
Loading…
Add table
Reference in a new issue