kitchen-ec2 3.10.0 → 3.10.1
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/aws/client.rb +7 -0
- data/lib/kitchen/driver/ec2.rb +1 -1
- data/lib/kitchen/driver/ec2_version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9bf47b3328885d0439de770cf9e683fb9bddbab66b0d0bf40f6ab17190c7cf15
|
4
|
+
data.tar.gz: 0e384572b5d252a367c9dd689f48d64764e4540a3ccba34399402eeca7a80226
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2dba5e5835f48d9505a967b7d1c64f76cfd70532a6956f8c8bada246814f5affa0ebfc09176354e7f719663347056f3332176489e64b8471f073cb2452f055f6
|
7
|
+
data.tar.gz: 787c72dc701db53331e399c0080d0bcce09d9657e8814bddf3d359186ed30d409391c068b545b09dbce9a527d0fcb793d3a79197058933f5f40d3d2dd21fcbeb
|
@@ -75,6 +75,13 @@ module Kitchen
|
|
75
75
|
).to_a[0]
|
76
76
|
end
|
77
77
|
|
78
|
+
# check if instance exists, given an id
|
79
|
+
# @param id [String] aws instance id
|
80
|
+
# @return boolean
|
81
|
+
def instance_exists?(id)
|
82
|
+
resource.instance(id).exists?
|
83
|
+
end
|
84
|
+
|
78
85
|
def client
|
79
86
|
@client ||= ::Aws::EC2::Client.new
|
80
87
|
end
|
data/lib/kitchen/driver/ec2.rb
CHANGED
@@ -285,7 +285,7 @@ module Kitchen
|
|
285
285
|
# If we are going to clean up an automatic security group, we need
|
286
286
|
# to wait for the instance to shut down. This slightly breaks the
|
287
287
|
# subsystem encapsulation, sorry not sorry.
|
288
|
-
if state[:auto_security_group_id] && server
|
288
|
+
if state[:auto_security_group_id] && server && ec2.instance_exists?(state[:server_id])
|
289
289
|
server.wait_until_terminated do |waiter|
|
290
290
|
waiter.max_attempts = config[:retryable_tries]
|
291
291
|
waiter.delay = config[:retryable_sleep]
|
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.10.
|
4
|
+
version: 3.10.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fletcher Nichol
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-10-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: test-kitchen
|
@@ -105,7 +105,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
105
105
|
- !ruby/object:Gem::Version
|
106
106
|
version: '0'
|
107
107
|
requirements: []
|
108
|
-
rubygems_version: 3.2.
|
108
|
+
rubygems_version: 3.2.22
|
109
109
|
signing_key:
|
110
110
|
specification_version: 4
|
111
111
|
summary: A Test Kitchen Driver for Amazon EC2
|