awspec 0.80.0 → 0.80.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/awspec/helper/finder/subnet.rb +13 -15
- data/lib/awspec/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 79351e0f4e5a1c92f7a8eff5f257148330acbbd6
|
4
|
+
data.tar.gz: 12789b620b3b6b9c90ffbcefa324fef5e8271883
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 95d4a780f9ac2c05a0edb44a13e1e6de4d5cb7e308d56cdfbba50b11d4610709e48330450b30f9b9e60e60b1c6d260249e97b8410b64c48e4184ab540b192b67
|
7
|
+
data.tar.gz: 2191c44374acb5cd7a48d660f5c200402653e77cf38f89fd348fea60376ab8f6ede60e9e6f15846bd5a97d03058ce25e13e4a8d60422afb934c00afd37992785
|
@@ -1,23 +1,21 @@
|
|
1
1
|
module Awspec::Helper
|
2
2
|
module Finder
|
3
3
|
module Subnet
|
4
|
-
def
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
def find_subnet(search_key)
|
4
|
+
def find_subnet(subnet_id)
|
5
|
+
res = ec2_client.describe_subnets({
|
6
|
+
filters: [{ name: 'subnet-id', values: [subnet_id] }]
|
7
|
+
})
|
8
|
+
resource = res.subnets.single_resource(subnet_id)
|
9
|
+
return resource if resource
|
10
|
+
res = ec2_client.describe_subnets({
|
11
|
+
filters: [{ name: 'tag:Name', values: [subnet_id] }]
|
12
|
+
})
|
13
|
+
resource = res.subnets.single_resource(subnet_id)
|
14
|
+
return resource if resource
|
17
15
|
res = ec2_client.describe_subnets({
|
18
|
-
filters: [{ name:
|
16
|
+
filters: [{ name: 'cidrBlock', values: [subnet_id] }]
|
19
17
|
})
|
20
|
-
res.subnets.single_resource(
|
18
|
+
res.subnets.single_resource(subnet_id)
|
21
19
|
end
|
22
20
|
|
23
21
|
def select_subnet_by_vpc_id(vpc_id)
|
data/lib/awspec/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: awspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.80.
|
4
|
+
version: 0.80.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- k1LoW
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-05-
|
11
|
+
date: 2017-05-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|