alpha_omega 0.0.220 → 0.0.222

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/VERSION +1 -1
  2. data/lib/alpha_omega/deploy.rb +5 -9
  3. metadata +1 -1
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.220
1
+ 0.0.222
@@ -33,6 +33,7 @@ Capistrano::Configuration.instance(:must_exist).load do |config|
33
33
  # are not sufficient.
34
34
  # =========================================================================
35
35
 
36
+ _cset :skip_scm, false
36
37
  _cset :scm, :git
37
38
  _cset :deploy_via, :checkout
38
39
  _cset(:branch) { AlphaOmega.what_branch }
@@ -278,11 +279,11 @@ Capistrano::Configuration.instance(:must_exist).load do |config|
278
279
  task :bootstrap_code do
279
280
  if releases.length < 2 # without services and run as root
280
281
  run "[[ -d #{deploy_to} ]] || #{try_sudo} install -d -m #{dir_perms} #{try_sudo.empty? ? '' : "-o #{root_user} -g #{root_group}"} #{deploy_to}"
281
- run "#{try_sudo} install -d -m #{dir_perms} #{try_sudo.empty? ? '' : "-o #{user} -g #{group}"} #{releases_path} #{deploy_to}/log"
282
+ run "#{try_sudo} install -d -m #{dir_perms}#{try_sudo.empty? ? '' : " -o #{user} -g #{group}"} #{releases_path} #{deploy_to}/#{log_dir} #{deploy_to}/#{cache_dir} #{deploy_to}/#{service_dir}"
282
283
  else
283
284
  dirs = [ releases_path, service_path, log_path, cache_path ]
284
285
  dir_args = dirs.map {|d| d.sub("#{deploy_to}/", "") }.join(' ')
285
- run "#{try_sudo} install -d -m #{dir_perms} #{try_sudo.empty? ? '' : "-o #{user} -g #{group}"} #{deploy_to}"
286
+ run "#{try_sudo} install -d -m #{dir_perms}#{try_sudo.empty? ? '' : " -o #{user} -g #{group}"} #{deploy_to}"
286
287
  run "cd #{deploy_to} && install -d -m #{dir_perms} #{dir_args}"
287
288
  end
288
289
  end
@@ -295,8 +296,7 @@ Capistrano::Configuration.instance(:must_exist).load do |config|
295
296
  task (if you want to perform the `restart' task separately).
296
297
  DESC
297
298
  task :update_code do
298
- bootstrap_code
299
- strategy.deploy!
299
+ strategy.deploy! unless skip_scm
300
300
  bundle
301
301
  cook
302
302
  unless deploy_path_name == migrate_path_name
@@ -589,15 +589,11 @@ Capistrano::Configuration.instance(:must_exist).load do |config|
589
589
  abort
590
590
  end
591
591
 
592
- run_script = <<-SCRIPT
593
- echo #{epoch} #{ENV['AO_USER']} > #{lock_path};
594
- SCRIPT
595
-
596
592
  if want_unlock
597
593
  at_exit { self.unlock; }
598
594
  end
599
595
 
600
- run run_script.gsub(/[\n\r]+[ \t]+/, " ")
596
+ run "echo #{epoch} #{ENV['AO_USER']} > #{lock_path}"
601
597
  end
602
598
 
603
599
  task :lock_compare do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alpha_omega
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.220
4
+ version: 0.0.222
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: