diff --git a/config/deploy.rb b/config/deploy.rb index 9b4ea4df0..53c64db45 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -13,6 +13,7 @@ require 'mina/rbenv' # forward_agent - SSH forward_agent # user - Username in the server to SSH to + if ENV['domain'].nil? raise "missing `domain`" end diff --git a/lib/tasks/deploy.rake b/lib/tasks/deploy.rake index 490ff5f99..6d02caf16 100644 --- a/lib/tasks/deploy.rake +++ b/lib/tasks/deploy.rake @@ -1,14 +1,14 @@ task :deploy do - domains = case ENV['STAGE_NAME'] + domains = case ENV['STAGE'] when 'dev' ['web1.dev', 'web2.dev'] when 'master' ['web1', 'web2'] else - raise "STAGE_NAME #{STAGE_NAME} is unknown. It must be either dev or master" + raise "STAGE #{STAGE} is unknown. It must be either dev or master" end - branch = ENV['STAGE_NAME'] + branch = ENV['STAGE'] domains.each do |domain| sh "mina deploy domain=#{domain} branch=#{branch} force_asset_precompile=true"