crazycode-cap-recipes 0.4.2 → 0.4.3

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
2
  :minor: 4
3
- :patch: 2
3
+ :patch: 3
4
4
  :build:
5
5
  :major: 0
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{crazycode-cap-recipes}
8
- s.version = "0.4.2"
8
+ s.version = "0.4.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["crazycode"]
@@ -15,8 +15,7 @@ Capistrano::Configuration.instance(true).load do |configuration|
15
15
  set :deploy_unit_code, ""
16
16
  set :deploy_stage, "development"
17
17
 
18
- set :deploy_id_file, ".deploy_id"
19
- set :tag, ""
18
+ set :build_version, ""
20
19
 
21
20
  role :app, :primary => true do
22
21
  CmdbService.get_app_role("#{cse_base}", deploy_unit_code, deploy_stage)
@@ -29,7 +28,7 @@ Capistrano::Configuration.instance(true).load do |configuration|
29
28
  task :deploy_to_tomcat, :roles => :single do
30
29
  codes = deploy_unit_code.split(/[,;\s]+/)
31
30
  deploy_hash = Hash.new
32
- codes.each {|code| deploy_hash[code] = CmdbService.start_deploy(cse_base, code, deploy_stage, tag) }
31
+ codes.each {|code| deploy_hash[code] = CmdbService.start_deploy(cse_base, code, deploy_stage, build_version) }
33
32
  begin
34
33
  gitdeploy.deploy
35
34
  tomcat.restart
@@ -14,6 +14,7 @@ Capistrano::Configuration.instance(true).load do |configuration|
14
14
  _cset :release_pattern, "*.war"
15
15
  _cset :upload_dir, ""
16
16
  _cset :shell_commands, "cd #{upload_dir}; ls -all"
17
+ _cset :build_version, "unset version"
17
18
 
18
19
  # role :app, :primary => true do
19
20
  # CmdbService.get_app_role("#{cse_base}", deploy_unit_code, deploy_stage)
@@ -53,6 +54,8 @@ Capistrano::Configuration.instance(true).load do |configuration|
53
54
  cp file, "#{release_dir}/#{target_name}"
54
55
  end
55
56
 
57
+ system "echo \"#{build_version}\" > #{release_dir}/version.txt"
58
+
56
59
  end
57
60
 
58
61
  desc "upload released file to remote hosts"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: crazycode-cap-recipes
3
3
  version: !ruby/object:Gem::Version
4
- hash: 11
4
+ hash: 9
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 4
9
- - 2
10
- version: 0.4.2
9
+ - 3
10
+ version: 0.4.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - crazycode