bosh_cli_plugin_micro 1.5.0.pre.1142 → 1.5.0.pre.1145

Sign up to get free protection for your applications and to get access to all the features.
@@ -156,7 +156,7 @@ module Bosh::Deployer
156
156
 
157
157
  # Capture stemcell and config sha1 here (end of the deployment)
158
158
  # to avoid locking deployer out if this deployment does not succeed
159
- save_fingerprints(stemcell_archive)
159
+ save_fingerprints(stemcell_tgz, stemcell_archive)
160
160
  end
161
161
  # rubocop:enable MethodLength
162
162
 
@@ -175,7 +175,7 @@ module Bosh::Deployer
175
175
  end
176
176
 
177
177
  def update(stemcell_tgz, stemcell_archive)
178
- result, message = has_pending_changes?(state, stemcell_archive)
178
+ result, message = has_pending_changes?(state, stemcell_tgz, stemcell_archive)
179
179
  @ui_messager.info(message)
180
180
 
181
181
  return unless result
@@ -542,15 +542,31 @@ module Bosh::Deployer
542
542
  end
543
543
  end
544
544
 
545
- def has_pending_changes?(state, stemcell_archive)
546
- return [true, :update_stemcell_unknown] unless stemcell_archive
547
- return [true, :update_stemcell_changed] if state.stemcell_sha1 != stemcell_archive.sha1
548
- return [true, :update_config_changed] if state.config_sha1 != @config_sha1
545
+ def has_pending_changes?(state, stemcell_tgz, stemcell_archive)
546
+ # If stemcell_archive is not provided
547
+ # it means that there is no file on the file system
548
+ # but rather we have a unique stemcell identifier (e.g. ami id)
549
+ if stemcell_archive
550
+ if state.stemcell_sha1 != stemcell_archive.sha1
551
+ return [true, :update_stemcell_changed]
552
+ end
553
+ elsif stemcell_tgz
554
+ if state.stemcell_sha1 != stemcell_tgz
555
+ return [true, :update_stemcell_changed]
556
+ end
557
+ else
558
+ return [true, :update_stemcell_unknown]
559
+ end
560
+
561
+ if state.config_sha1 != @config_sha1
562
+ return [true, :update_config_changed]
563
+ end
564
+
549
565
  [false, :update_no_changes]
550
566
  end
551
567
 
552
- def save_fingerprints(stemcell_archive)
553
- state.stemcell_sha1 = stemcell_archive ? stemcell_archive.sha1 : nil
568
+ def save_fingerprints(stemcell_tgz, stemcell_archive)
569
+ state.stemcell_sha1 = stemcell_archive ? stemcell_archive.sha1 : stemcell_tgz
554
570
  state.config_sha1 = @config_sha1
555
571
  save_state
556
572
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Bosh
4
4
  module Deployer
5
- VERSION = '1.5.0.pre.1142'
5
+ VERSION = '1.5.0.pre.1145'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bosh_cli_plugin_micro
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0.pre.1142
4
+ version: 1.5.0.pre.1145
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-10-22 00:00:00.000000000 Z
12
+ date: 2013-10-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: sqlite3
@@ -34,7 +34,7 @@ dependencies:
34
34
  requirements:
35
35
  - - ~>
36
36
  - !ruby/object:Gem::Version
37
- version: 1.5.0.pre.1142
37
+ version: 1.5.0.pre.1145
38
38
  type: :runtime
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
@@ -42,7 +42,7 @@ dependencies:
42
42
  requirements:
43
43
  - - ~>
44
44
  - !ruby/object:Gem::Version
45
- version: 1.5.0.pre.1142
45
+ version: 1.5.0.pre.1145
46
46
  - !ruby/object:Gem::Dependency
47
47
  name: bosh-stemcell
48
48
  requirement: !ruby/object:Gem::Requirement
@@ -50,7 +50,7 @@ dependencies:
50
50
  requirements:
51
51
  - - ~>
52
52
  - !ruby/object:Gem::Version
53
- version: 1.5.0.pre.1142
53
+ version: 1.5.0.pre.1145
54
54
  type: :runtime
55
55
  prerelease: false
56
56
  version_requirements: !ruby/object:Gem::Requirement
@@ -58,7 +58,7 @@ dependencies:
58
58
  requirements:
59
59
  - - ~>
60
60
  - !ruby/object:Gem::Version
61
- version: 1.5.0.pre.1142
61
+ version: 1.5.0.pre.1145
62
62
  - !ruby/object:Gem::Dependency
63
63
  name: bosh-registry
64
64
  requirement: !ruby/object:Gem::Requirement
@@ -66,7 +66,7 @@ dependencies:
66
66
  requirements:
67
67
  - - ~>
68
68
  - !ruby/object:Gem::Version
69
- version: 1.5.0.pre.1142
69
+ version: 1.5.0.pre.1145
70
70
  type: :runtime
71
71
  prerelease: false
72
72
  version_requirements: !ruby/object:Gem::Requirement
@@ -74,7 +74,7 @@ dependencies:
74
74
  requirements:
75
75
  - - ~>
76
76
  - !ruby/object:Gem::Version
77
- version: 1.5.0.pre.1142
77
+ version: 1.5.0.pre.1145
78
78
  - !ruby/object:Gem::Dependency
79
79
  name: agent_client
80
80
  requirement: !ruby/object:Gem::Requirement
@@ -82,7 +82,7 @@ dependencies:
82
82
  requirements:
83
83
  - - ~>
84
84
  - !ruby/object:Gem::Version
85
- version: 1.5.0.pre.1142
85
+ version: 1.5.0.pre.1145
86
86
  type: :runtime
87
87
  prerelease: false
88
88
  version_requirements: !ruby/object:Gem::Requirement
@@ -90,7 +90,7 @@ dependencies:
90
90
  requirements:
91
91
  - - ~>
92
92
  - !ruby/object:Gem::Version
93
- version: 1.5.0.pre.1142
93
+ version: 1.5.0.pre.1145
94
94
  - !ruby/object:Gem::Dependency
95
95
  name: bosh_cpi
96
96
  requirement: !ruby/object:Gem::Requirement
@@ -98,7 +98,7 @@ dependencies:
98
98
  requirements:
99
99
  - - ~>
100
100
  - !ruby/object:Gem::Version
101
- version: 1.5.0.pre.1142
101
+ version: 1.5.0.pre.1145
102
102
  type: :runtime
103
103
  prerelease: false
104
104
  version_requirements: !ruby/object:Gem::Requirement
@@ -106,7 +106,7 @@ dependencies:
106
106
  requirements:
107
107
  - - ~>
108
108
  - !ruby/object:Gem::Version
109
- version: 1.5.0.pre.1142
109
+ version: 1.5.0.pre.1145
110
110
  - !ruby/object:Gem::Dependency
111
111
  name: bosh_aws_cpi
112
112
  requirement: !ruby/object:Gem::Requirement
@@ -114,7 +114,7 @@ dependencies:
114
114
  requirements:
115
115
  - - ~>
116
116
  - !ruby/object:Gem::Version
117
- version: 1.5.0.pre.1142
117
+ version: 1.5.0.pre.1145
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
@@ -122,7 +122,7 @@ dependencies:
122
122
  requirements:
123
123
  - - ~>
124
124
  - !ruby/object:Gem::Version
125
- version: 1.5.0.pre.1142
125
+ version: 1.5.0.pre.1145
126
126
  - !ruby/object:Gem::Dependency
127
127
  name: bosh_openstack_cpi
128
128
  requirement: !ruby/object:Gem::Requirement
@@ -130,7 +130,7 @@ dependencies:
130
130
  requirements:
131
131
  - - ~>
132
132
  - !ruby/object:Gem::Version
133
- version: 1.5.0.pre.1142
133
+ version: 1.5.0.pre.1145
134
134
  type: :runtime
135
135
  prerelease: false
136
136
  version_requirements: !ruby/object:Gem::Requirement
@@ -138,7 +138,7 @@ dependencies:
138
138
  requirements:
139
139
  - - ~>
140
140
  - !ruby/object:Gem::Version
141
- version: 1.5.0.pre.1142
141
+ version: 1.5.0.pre.1145
142
142
  - !ruby/object:Gem::Dependency
143
143
  name: bosh_vcloud_cpi
144
144
  requirement: !ruby/object:Gem::Requirement
@@ -162,7 +162,7 @@ dependencies:
162
162
  requirements:
163
163
  - - ~>
164
164
  - !ruby/object:Gem::Version
165
- version: 1.5.0.pre.1142
165
+ version: 1.5.0.pre.1145
166
166
  type: :runtime
167
167
  prerelease: false
168
168
  version_requirements: !ruby/object:Gem::Requirement
@@ -170,7 +170,7 @@ dependencies:
170
170
  requirements:
171
171
  - - ~>
172
172
  - !ruby/object:Gem::Version
173
- version: 1.5.0.pre.1142
173
+ version: 1.5.0.pre.1145
174
174
  - !ruby/object:Gem::Dependency
175
175
  name: rspec-fire
176
176
  requirement: !ruby/object:Gem::Requirement
@@ -189,7 +189,7 @@ dependencies:
189
189
  version: '0'
190
190
  description: ! 'BOSH CLI plugin for Micro BOSH deployment
191
191
 
192
- 31eb14'
192
+ 715d8f'
193
193
  email: support@cloudfoundry.com
194
194
  executables: []
195
195
  extensions: []