formatron 0.1.5 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4b391d6146eb8e840246141cb00b355b5069cd31
|
4
|
+
data.tar.gz: ed27b190cb60992e526e13ee3eca416dd8390c78
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a31d0d96bf15f28c1b75e20761030e2358e140f6ec62259594bd19a6cff848485047cd606007a6f2f9ede5bef7845a4d2136b828184e8afab5e1a406891b8b22
|
7
|
+
data.tar.gz: 91e0382a3418c6b3c449caadd95c4696a83cf0a2a292ee09c38a8e1c096d993b2270e5b9f8b74a3047113756b4265c104a7e2cd4e7a6887f7f2aaba314ca30e0
|
@@ -23,6 +23,7 @@ class Formatron
|
|
23
23
|
PRIVATE_RECORD_SET_PREFIX = 'privateRecordSet'
|
24
24
|
PUBLIC_RECORD_SET_PREFIX = 'publicRecordSet'
|
25
25
|
PUBLIC_ALIAS_RECORD_SET_PREFIX = 'publicAliasRecordSet'
|
26
|
+
PRIVATE_ALIAS_RECORD_SET_PREFIX = 'privateAliasRecordSet'
|
26
27
|
VOLUME_PREFIX = 'volume'
|
27
28
|
VOLUME_ATTACHMENT_PREFIX = 'volumeAttachment'
|
28
29
|
|
@@ -79,6 +80,7 @@ class Formatron
|
|
79
80
|
@public_record_set_id =
|
80
81
|
"#{PUBLIC_RECORD_SET_PREFIX}#{@guid}"
|
81
82
|
@public_aliases = @instance.public_alias
|
83
|
+
@private_aliases = @instance.private_alias
|
82
84
|
@volumes = @instance.volume
|
83
85
|
@bucket = bucket
|
84
86
|
@name = name
|
@@ -162,6 +164,7 @@ class Formatron
|
|
162
164
|
attribute: 'PublicIp'
|
163
165
|
) unless @public_hosted_zone_id.nil?
|
164
166
|
_add_public_aliases resources unless @public_hosted_zone_id.nil?
|
167
|
+
_add_private_aliases resources
|
165
168
|
_add_volumes resources
|
166
169
|
end
|
167
170
|
# rubocop:enable Metrics/AbcSize
|
@@ -183,6 +186,23 @@ class Formatron
|
|
183
186
|
end
|
184
187
|
# rubocop:enable Metrics/MethodLength
|
185
188
|
|
189
|
+
# rubocop:disable Metrics/MethodLength
|
190
|
+
def _add_private_aliases(resources)
|
191
|
+
@private_aliases.each_index do |index|
|
192
|
+
sub_domain = @private_aliases[index]
|
193
|
+
logical_id =
|
194
|
+
"#{PRIVATE_ALIAS_RECORD_SET_PREFIX}#{index}#{@guid}"
|
195
|
+
resources[logical_id] = Resources::Route53.record_set(
|
196
|
+
hosted_zone_id: @private_hosted_zone_id,
|
197
|
+
sub_domain: sub_domain,
|
198
|
+
hosted_zone_name: @hosted_zone_name,
|
199
|
+
instance: @instance_id,
|
200
|
+
attribute: 'PrivateIp'
|
201
|
+
)
|
202
|
+
end
|
203
|
+
end
|
204
|
+
# rubocop:enable Metrics/MethodLength
|
205
|
+
|
186
206
|
# rubocop:disable Metrics/MethodLength
|
187
207
|
def _add_volumes(resources)
|
188
208
|
@volumes.each_index do |index|
|
@@ -208,6 +228,7 @@ class Formatron
|
|
208
228
|
|
209
229
|
private(
|
210
230
|
:_add_public_aliases,
|
231
|
+
:_add_private_aliases,
|
211
232
|
:_add_volumes
|
212
233
|
)
|
213
234
|
end
|
data/lib/formatron/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: formatron
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Halliday
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-11-
|
11
|
+
date: 2015-11-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -413,7 +413,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
413
413
|
version: '0'
|
414
414
|
requirements: []
|
415
415
|
rubyforge_project:
|
416
|
-
rubygems_version: 2.
|
416
|
+
rubygems_version: 2.4.5.1
|
417
417
|
signing_key:
|
418
418
|
specification_version: 4
|
419
419
|
summary: AWS/Chef Deployment Tool
|