cfndsl 1.5.0 → 1.7.2

Sign up to get free protection for your applications and to get access to all the features.
data/lib/cfndsl/types.rb CHANGED
@@ -38,7 +38,7 @@ module CfnDsl
38
38
  # some json incorrectly labelled as Type -> Json instead of PrimitiveType
39
39
  # also, AWS now has the concept of Map which cfndsl had never defined
40
40
  property_type =
41
- if property_info['Type'] == 'Map' || property_info['Type'] == 'Json'
41
+ if %w[Map Json].include?(property_info['Type'])
42
42
  'Json'
43
43
  elsif property_info['PrimitiveType']
44
44
  property_info['PrimitiveType']
@@ -96,7 +96,7 @@ module CfnDsl
96
96
  elsif property_info.key?('Properties')
97
97
  property_info['Properties'].each_with_object({}) do |(nested_prop_name, nested_prop_info), extracted|
98
98
  nested_prop_type =
99
- if nested_prop_info['Type'] == 'Map' || nested_prop_info['Type'] == 'Json'
99
+ if %w[Map Json].include?(nested_prop_info['Type'])
100
100
  # The Map type and the incorrectly labelled Json type
101
101
  'Json'
102
102
  elsif nested_prop_info['PrimitiveType']
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CfnDsl
4
- VERSION = '1.5.0'
4
+ VERSION = '1.7.2'
5
5
  end
@@ -60,7 +60,7 @@ CloudFormation do
60
60
  )
61
61
  end
62
62
 
63
- Topic('ConfigServiceTopic') do
63
+ SNS_Topic('ConfigServiceTopic') do
64
64
  DisplayName 'ConfigSvc'
65
65
  Subscription [{
66
66
  'Endpoint' => FnGetAtt('ConfigServiceQueue', 'Arn'),
@@ -9,7 +9,9 @@ describe Cfnlego do
9
9
  it 'formats correctly' do
10
10
  output = "require 'cfndsl'\nCloudFormation do\n Description 'auto generated cloudformation cfndsl template'\n\n "
11
11
  output << " EC2_EIP('EIP') do"
12
+ output << "\n Address String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-address"
12
13
  output << "\n InstanceId String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-instanceid"
14
+ output << "\n IpamPoolId String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-ipampoolid"
13
15
  output << "\n PublicIpv4Pool String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-publicipv4pool"
14
16
  output << "\n TransferAddress String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-transferaddress"
15
17
  output << "\n Domain String # http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-eip.html#cfn-ec2-eip-domain"
metadata CHANGED
@@ -1,17 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cfndsl
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steven Jack
8
8
  - Chris Howe
9
9
  - Travis Dempsey
10
10
  - Greg Cockburn
11
- autorequire:
12
11
  bindir: exe
13
12
  cert_chain: []
14
- date: 2022-12-28 00:00:00.000000000 Z
13
+ date: 2025-01-21 00:00:00.000000000 Z
15
14
  dependencies:
16
15
  - !ruby/object:Gem::Dependency
17
16
  name: bundler
@@ -78,7 +77,6 @@ files:
78
77
  - lib/cfndsl/aws/patches/500_NetworkAclEntry_patch.json
79
78
  - lib/cfndsl/aws/patches/500_SAM_Serverless_Function_S3Event_Events_patch.json
80
79
  - lib/cfndsl/aws/patches/500_SAM_Serverless_Function_S3Location_Version_patch.json
81
- - lib/cfndsl/aws/patches/500_SSM_AssociationName_patch.json
82
80
  - lib/cfndsl/aws/patches/500_VPCEndpoint_patch.json
83
81
  - lib/cfndsl/aws/patches/510_ElasticSearch_Domain_patches.json
84
82
  - lib/cfndsl/aws/patches/520_ServiceDiscovery_InstanceAttributes_patch.json
@@ -179,7 +177,6 @@ homepage: https://github.com/cfndsl/cfndsl
179
177
  licenses:
180
178
  - MIT
181
179
  metadata: {}
182
- post_install_message:
183
180
  rdoc_options: []
184
181
  require_paths:
185
182
  - lib
@@ -194,8 +191,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
194
191
  - !ruby/object:Gem::Version
195
192
  version: '0'
196
193
  requirements: []
197
- rubygems_version: 3.4.1
198
- signing_key:
194
+ rubygems_version: 3.6.2
199
195
  specification_version: 4
200
196
  summary: AWS Cloudformation DSL
201
197
  test_files:
@@ -1,16 +0,0 @@
1
- {
2
- "ResourceTypes": {
3
- "AWS::SSM::Association": {
4
- "patch": {
5
- "description": "rename +Name+ to +DocumentName+ to clearly indicate what the attribute is for",
6
- "operations": [
7
- {
8
- "from": "/Properties/Name",
9
- "op": "move",
10
- "path": "/Properties/DocumentName"
11
- }
12
- ]
13
- }
14
- }
15
- }
16
- }