kitchen-ec2 3.0.0.preview → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/kitchen/driver/ec2.rb +9 -7
- data/lib/kitchen/driver/ec2_version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2598523d69ee636b7383ade030343fa34a921812bd5b74bae8150c9285de77af
|
4
|
+
data.tar.gz: 8c04663e1da6191dacb4c99e18884f1576a047f29a778349bcaa51dadc50d37a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b406e3e5b3def37fe92698fc78ef262da1014b755a9bb29fd1035e327d583d7923cd7ae14ee7205489657b22f141dfe2f9bc093dfc94f374bc81acbed4685047
|
7
|
+
data.tar.gz: c2260e73a83db918ee7b1d90572f42aa90289f78112c61eb45737b2cc1ce1537a5ecc332c8699322f22e33c6fc791929eb82ff7bbc278a386a8738f9b4aa8c31
|
data/lib/kitchen/driver/ec2.rb
CHANGED
@@ -229,15 +229,17 @@ module Kitchen
|
|
229
229
|
|
230
230
|
if config[:spot_price]
|
231
231
|
# Spot instance when a price is set
|
232
|
-
server = submit_spot(state)
|
232
|
+
server = with_request_limit_backoff(state) { submit_spot(state) }
|
233
233
|
else
|
234
234
|
# On-demand instance
|
235
|
-
server = submit_server
|
235
|
+
server = with_request_limit_backoff(state) { submit_server }
|
236
236
|
end
|
237
237
|
info("Instance <#{server.id}> requested.")
|
238
|
-
|
239
|
-
|
240
|
-
|
238
|
+
with_request_limit_backoff(state) do
|
239
|
+
server.wait_until_exists do |w|
|
240
|
+
w.before_attempt do |attempts|
|
241
|
+
info("Polling AWS for existence, attempt #{attempts}...")
|
242
|
+
end
|
241
243
|
end
|
242
244
|
end
|
243
245
|
|
@@ -463,7 +465,7 @@ module Kitchen
|
|
463
465
|
# we convert the value to a string because
|
464
466
|
# nils should be passed as an empty String
|
465
467
|
# and Integers need to be represented as Strings
|
466
|
-
{ key: k, value: v.to_s }
|
468
|
+
{ key: k.to_s, value: v.to_s }
|
467
469
|
end
|
468
470
|
server.create_tags(tags: tags)
|
469
471
|
end
|
@@ -472,7 +474,7 @@ module Kitchen
|
|
472
474
|
def tag_volumes(server)
|
473
475
|
if config[:tags] && !config[:tags].empty?
|
474
476
|
tags = config[:tags].map do |k, v|
|
475
|
-
{ key: k, value: v.to_s }
|
477
|
+
{ key: k.to_s, value: v.to_s }
|
476
478
|
end
|
477
479
|
server.volumes.each do |volume|
|
478
480
|
volume.create_tags(tags: tags)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kitchen-ec2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.0
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fletcher Nichol
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-05-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: test-kitchen
|
@@ -221,9 +221,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
221
221
|
version: '2.3'
|
222
222
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
223
223
|
requirements:
|
224
|
-
- - "
|
224
|
+
- - ">="
|
225
225
|
- !ruby/object:Gem::Version
|
226
|
-
version:
|
226
|
+
version: '0'
|
227
227
|
requirements: []
|
228
228
|
rubygems_version: 3.0.3
|
229
229
|
signing_key:
|