@aws-solutions-constructs/aws-lambda-elasticachememcached 2.51.0 → 2.52.1

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.
Files changed (44) hide show
  1. package/.eslintignore +2 -0
  2. package/.jsii +49 -4
  3. package/integ.config.json +7 -0
  4. package/lib/index.js +1 -1
  5. package/package.json +9 -8
  6. package/test/integ.lammem-existingResources.js +6 -2
  7. package/test/integ.lammem-existingResources.js.snapshot/asset.c1b23d6af38c04acb744bda25a3dc7f4394daea942c67eaff40911a707a3c37a/index.js +8 -0
  8. package/test/integ.lammem-existingResources.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/__entrypoint__.js +1 -0
  9. package/test/integ.lammem-existingResources.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/index.js +1 -0
  10. package/test/integ.lammem-existingResources.js.snapshot/cdk.out +1 -0
  11. package/test/integ.lammem-existingResources.js.snapshot/integ.json +12 -0
  12. package/test/integ.lammem-existingResources.js.snapshot/lammem-existingResources.assets.json +45 -0
  13. package/test/integ.lammem-existingResources.js.snapshot/lammem-existingResources.template.json +720 -0
  14. package/test/integ.lammem-existingResources.js.snapshot/lammemexistingResourcesIntegDefaultTestDeployAssertD269DF67.assets.json +19 -0
  15. package/test/integ.lammem-existingResources.js.snapshot/lammemexistingResourcesIntegDefaultTestDeployAssertD269DF67.template.json +36 -0
  16. package/test/integ.lammem-existingResources.js.snapshot/manifest.json +239 -0
  17. package/test/integ.lammem-existingResources.js.snapshot/tree.json +947 -0
  18. package/test/integ.lammem-newResources.js +6 -2
  19. package/test/integ.lammem-newResources.js.snapshot/asset.c1b23d6af38c04acb744bda25a3dc7f4394daea942c67eaff40911a707a3c37a/index.js +8 -0
  20. package/test/integ.lammem-newResources.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/__entrypoint__.js +1 -0
  21. package/test/integ.lammem-newResources.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/index.js +1 -0
  22. package/test/integ.lammem-newResources.js.snapshot/cdk.out +1 -0
  23. package/test/integ.lammem-newResources.js.snapshot/integ.json +12 -0
  24. package/test/integ.lammem-newResources.js.snapshot/lammem-newResources.assets.json +45 -0
  25. package/test/integ.lammem-newResources.js.snapshot/lammem-newResources.template.json +726 -0
  26. package/test/integ.lammem-newResources.js.snapshot/lammemnewResourcesIntegDefaultTestDeployAssert30C906BF.assets.json +19 -0
  27. package/test/integ.lammem-newResources.js.snapshot/lammemnewResourcesIntegDefaultTestDeployAssert30C906BF.template.json +36 -0
  28. package/test/integ.lammem-newResources.js.snapshot/manifest.json +239 -0
  29. package/test/integ.lammem-newResources.js.snapshot/tree.json +966 -0
  30. package/test/integ.lammem-withClientProps.js +6 -2
  31. package/test/integ.lammem-withClientProps.js.snapshot/asset.c1b23d6af38c04acb744bda25a3dc7f4394daea942c67eaff40911a707a3c37a/index.js +8 -0
  32. package/test/integ.lammem-withClientProps.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/__entrypoint__.js +1 -0
  33. package/test/integ.lammem-withClientProps.js.snapshot/asset.dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e/index.js +1 -0
  34. package/test/integ.lammem-withClientProps.js.snapshot/cdk.out +1 -0
  35. package/test/integ.lammem-withClientProps.js.snapshot/integ.json +12 -0
  36. package/test/integ.lammem-withClientProps.js.snapshot/lammem-withClientProps.assets.json +45 -0
  37. package/test/integ.lammem-withClientProps.js.snapshot/lammem-withClientProps.template.json +726 -0
  38. package/test/integ.lammem-withClientProps.js.snapshot/lammemwithClientPropsIntegDefaultTestDeployAssertDB086BD1.assets.json +19 -0
  39. package/test/integ.lammem-withClientProps.js.snapshot/lammemwithClientPropsIntegDefaultTestDeployAssertDB086BD1.template.json +36 -0
  40. package/test/integ.lammem-withClientProps.js.snapshot/manifest.json +239 -0
  41. package/test/integ.lammem-withClientProps.js.snapshot/tree.json +966 -0
  42. package/test/integ.lammem-existingResources.expected.json +0 -630
  43. package/test/integ.lammem-newResources.expected.json +0 -641
  44. package/test/integ.lammem-withClientProps.expected.json +0 -641
@@ -0,0 +1,726 @@
1
+ {
2
+ "Description": "Integration Test with new resourcesfor aws-lambda-elasticachememcached",
3
+ "Resources": {
4
+ "lammemnewResourceslammemnewResourcescachesg08EE8773": {
5
+ "Type": "AWS::EC2::SecurityGroup",
6
+ "Properties": {
7
+ "GroupDescription": "lammem-newResources/lammem-newResources/lammem-newResources-cachesg",
8
+ "SecurityGroupEgress": [
9
+ {
10
+ "CidrIp": "0.0.0.0/0",
11
+ "Description": "Allow all outbound traffic by default",
12
+ "IpProtocol": "-1"
13
+ }
14
+ ],
15
+ "VpcId": {
16
+ "Ref": "Vpc8378EB38"
17
+ }
18
+ },
19
+ "Metadata": {
20
+ "cfn_nag": {
21
+ "rules_to_suppress": [
22
+ {
23
+ "id": "W5",
24
+ "reason": "Egress of 0.0.0.0/0 is default and generally considered OK"
25
+ },
26
+ {
27
+ "id": "W40",
28
+ "reason": "Egress IPProtocol of -1 is default and generally considered OK"
29
+ }
30
+ ]
31
+ }
32
+ }
33
+ },
34
+ "lammemnewResourceslammemnewResourcesingress6740B3EB": {
35
+ "Type": "AWS::EC2::SecurityGroupIngress",
36
+ "Properties": {
37
+ "Description": "Self referencing rule to control access to Elasticache memcached cluster",
38
+ "FromPort": 11222,
39
+ "GroupId": {
40
+ "Fn::GetAtt": [
41
+ "lammemnewResourceslammemnewResourcescachesg08EE8773",
42
+ "GroupId"
43
+ ]
44
+ },
45
+ "IpProtocol": "TCP",
46
+ "SourceSecurityGroupId": {
47
+ "Fn::GetAtt": [
48
+ "lammemnewResourceslammemnewResourcescachesg08EE8773",
49
+ "GroupId"
50
+ ]
51
+ },
52
+ "ToPort": 11222
53
+ },
54
+ "DependsOn": [
55
+ "lammemnewResourceslammemnewResourcescachesg08EE8773"
56
+ ]
57
+ },
58
+ "lammemnewResourcesecsubnetgrouplammemnewResourcesBFA66192": {
59
+ "Type": "AWS::ElastiCache::SubnetGroup",
60
+ "Properties": {
61
+ "CacheSubnetGroupName": "lammem-newResources-subnet-group",
62
+ "Description": "Solutions Constructs generated Cache Subnet Group",
63
+ "SubnetIds": [
64
+ {
65
+ "Ref": "VpcisolatedSubnet1SubnetE62B1B9B"
66
+ },
67
+ {
68
+ "Ref": "VpcisolatedSubnet2Subnet39217055"
69
+ }
70
+ ]
71
+ }
72
+ },
73
+ "lammemnewResourceslammemnewResourcescluster026E518E": {
74
+ "Type": "AWS::ElastiCache::CacheCluster",
75
+ "Properties": {
76
+ "AZMode": "cross-az",
77
+ "CacheNodeType": "cache.t3.medium",
78
+ "CacheSubnetGroupName": "lammem-newResources-subnet-group",
79
+ "ClusterName": "lammem-newResources-cdk-cluster",
80
+ "Engine": "memcached",
81
+ "NumCacheNodes": 2,
82
+ "Port": 11222,
83
+ "VpcSecurityGroupIds": [
84
+ {
85
+ "Fn::GetAtt": [
86
+ "lammemnewResourceslammemnewResourcescachesg08EE8773",
87
+ "GroupId"
88
+ ]
89
+ }
90
+ ]
91
+ },
92
+ "DependsOn": [
93
+ "lammemnewResourcesecsubnetgrouplammemnewResourcesBFA66192"
94
+ ]
95
+ },
96
+ "lammemnewResourcesLambdaFunctionServiceRoleDB5D0991": {
97
+ "Type": "AWS::IAM::Role",
98
+ "Properties": {
99
+ "AssumeRolePolicyDocument": {
100
+ "Statement": [
101
+ {
102
+ "Action": "sts:AssumeRole",
103
+ "Effect": "Allow",
104
+ "Principal": {
105
+ "Service": "lambda.amazonaws.com"
106
+ }
107
+ }
108
+ ],
109
+ "Version": "2012-10-17"
110
+ },
111
+ "Policies": [
112
+ {
113
+ "PolicyDocument": {
114
+ "Statement": [
115
+ {
116
+ "Action": [
117
+ "logs:CreateLogGroup",
118
+ "logs:CreateLogStream",
119
+ "logs:PutLogEvents"
120
+ ],
121
+ "Effect": "Allow",
122
+ "Resource": {
123
+ "Fn::Join": [
124
+ "",
125
+ [
126
+ "arn:",
127
+ {
128
+ "Ref": "AWS::Partition"
129
+ },
130
+ ":logs:",
131
+ {
132
+ "Ref": "AWS::Region"
133
+ },
134
+ ":",
135
+ {
136
+ "Ref": "AWS::AccountId"
137
+ },
138
+ ":log-group:/aws/lambda/*"
139
+ ]
140
+ ]
141
+ }
142
+ }
143
+ ],
144
+ "Version": "2012-10-17"
145
+ },
146
+ "PolicyName": "LambdaFunctionServiceRolePolicy"
147
+ }
148
+ ]
149
+ }
150
+ },
151
+ "lammemnewResourcesLambdaFunctionServiceRoleDefaultPolicyBEBDF814": {
152
+ "Type": "AWS::IAM::Policy",
153
+ "Properties": {
154
+ "PolicyDocument": {
155
+ "Statement": [
156
+ {
157
+ "Action": [
158
+ "ec2:AssignPrivateIpAddresses",
159
+ "ec2:CreateNetworkInterface",
160
+ "ec2:DeleteNetworkInterface",
161
+ "ec2:DescribeNetworkInterfaces",
162
+ "ec2:UnassignPrivateIpAddresses",
163
+ "xray:PutTelemetryRecords",
164
+ "xray:PutTraceSegments"
165
+ ],
166
+ "Effect": "Allow",
167
+ "Resource": "*"
168
+ }
169
+ ],
170
+ "Version": "2012-10-17"
171
+ },
172
+ "PolicyName": "lammemnewResourcesLambdaFunctionServiceRoleDefaultPolicyBEBDF814",
173
+ "Roles": [
174
+ {
175
+ "Ref": "lammemnewResourcesLambdaFunctionServiceRoleDB5D0991"
176
+ }
177
+ ]
178
+ },
179
+ "Metadata": {
180
+ "cfn_nag": {
181
+ "rules_to_suppress": [
182
+ {
183
+ "id": "W12",
184
+ "reason": "Lambda needs the following minimum required permissions to send trace data to X-Ray and access ENIs in a VPC."
185
+ }
186
+ ]
187
+ }
188
+ }
189
+ },
190
+ "lammemnewResourcesReplaceDefaultSecurityGroupsecuritygroup6C020299": {
191
+ "Type": "AWS::EC2::SecurityGroup",
192
+ "Properties": {
193
+ "GroupDescription": "lammem-newResources/lammem-newResources/ReplaceDefaultSecurityGroup-security-group",
194
+ "SecurityGroupEgress": [
195
+ {
196
+ "CidrIp": "0.0.0.0/0",
197
+ "Description": "Allow all outbound traffic by default",
198
+ "IpProtocol": "-1"
199
+ }
200
+ ],
201
+ "VpcId": {
202
+ "Ref": "Vpc8378EB38"
203
+ }
204
+ },
205
+ "Metadata": {
206
+ "cfn_nag": {
207
+ "rules_to_suppress": [
208
+ {
209
+ "id": "W5",
210
+ "reason": "Egress of 0.0.0.0/0 is default and generally considered OK"
211
+ },
212
+ {
213
+ "id": "W40",
214
+ "reason": "Egress IPProtocol of -1 is default and generally considered OK"
215
+ }
216
+ ]
217
+ }
218
+ }
219
+ },
220
+ "lammemnewResourcesLambdaFunction960422D5": {
221
+ "Type": "AWS::Lambda::Function",
222
+ "Properties": {
223
+ "Code": {
224
+ "S3Bucket": {
225
+ "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
226
+ },
227
+ "S3Key": "c1b23d6af38c04acb744bda25a3dc7f4394daea942c67eaff40911a707a3c37a.zip"
228
+ },
229
+ "Environment": {
230
+ "Variables": {
231
+ "AWS_NODEJS_CONNECTION_REUSE_ENABLED": "1",
232
+ "CACHE_ENDPOINT": {
233
+ "Fn::Join": [
234
+ "",
235
+ [
236
+ {
237
+ "Fn::GetAtt": [
238
+ "lammemnewResourceslammemnewResourcescluster026E518E",
239
+ "ConfigurationEndpoint.Address"
240
+ ]
241
+ },
242
+ ":",
243
+ {
244
+ "Fn::GetAtt": [
245
+ "lammemnewResourceslammemnewResourcescluster026E518E",
246
+ "ConfigurationEndpoint.Port"
247
+ ]
248
+ }
249
+ ]
250
+ ]
251
+ }
252
+ }
253
+ },
254
+ "Handler": "index.handler",
255
+ "Role": {
256
+ "Fn::GetAtt": [
257
+ "lammemnewResourcesLambdaFunctionServiceRoleDB5D0991",
258
+ "Arn"
259
+ ]
260
+ },
261
+ "Runtime": "nodejs16.x",
262
+ "TracingConfig": {
263
+ "Mode": "Active"
264
+ },
265
+ "VpcConfig": {
266
+ "SecurityGroupIds": [
267
+ {
268
+ "Fn::GetAtt": [
269
+ "lammemnewResourceslammemnewResourcescachesg08EE8773",
270
+ "GroupId"
271
+ ]
272
+ },
273
+ {
274
+ "Fn::GetAtt": [
275
+ "lammemnewResourcesReplaceDefaultSecurityGroupsecuritygroup6C020299",
276
+ "GroupId"
277
+ ]
278
+ }
279
+ ],
280
+ "SubnetIds": [
281
+ {
282
+ "Ref": "VpcisolatedSubnet1SubnetE62B1B9B"
283
+ },
284
+ {
285
+ "Ref": "VpcisolatedSubnet2Subnet39217055"
286
+ }
287
+ ]
288
+ }
289
+ },
290
+ "DependsOn": [
291
+ "lammemnewResourcesLambdaFunctionServiceRoleDefaultPolicyBEBDF814",
292
+ "lammemnewResourcesLambdaFunctionServiceRoleDB5D0991",
293
+ "VpcisolatedSubnet1RouteTableAssociationD259E31A",
294
+ "VpcisolatedSubnet2RouteTableAssociation25A4716F"
295
+ ],
296
+ "Metadata": {
297
+ "cfn_nag": {
298
+ "rules_to_suppress": [
299
+ {
300
+ "id": "W58",
301
+ "reason": "Lambda functions has the required permission to write CloudWatch Logs. It uses custom policy instead of arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole with tighter permissions."
302
+ },
303
+ {
304
+ "id": "W89",
305
+ "reason": "This is not a rule for the general case, just for specific use cases/industries"
306
+ },
307
+ {
308
+ "id": "W92",
309
+ "reason": "Impossible for us to define the correct concurrency for clients"
310
+ }
311
+ ]
312
+ }
313
+ }
314
+ },
315
+ "Vpc8378EB38": {
316
+ "Type": "AWS::EC2::VPC",
317
+ "Properties": {
318
+ "CidrBlock": "10.0.0.0/16",
319
+ "EnableDnsHostnames": true,
320
+ "EnableDnsSupport": true,
321
+ "InstanceTenancy": "default",
322
+ "Tags": [
323
+ {
324
+ "Key": "Name",
325
+ "Value": "lammem-newResources/Vpc"
326
+ }
327
+ ]
328
+ }
329
+ },
330
+ "VpcisolatedSubnet1SubnetE62B1B9B": {
331
+ "Type": "AWS::EC2::Subnet",
332
+ "Properties": {
333
+ "AvailabilityZone": {
334
+ "Fn::Select": [
335
+ 0,
336
+ {
337
+ "Fn::GetAZs": ""
338
+ }
339
+ ]
340
+ },
341
+ "CidrBlock": "10.0.0.0/18",
342
+ "MapPublicIpOnLaunch": false,
343
+ "Tags": [
344
+ {
345
+ "Key": "aws-cdk:subnet-name",
346
+ "Value": "isolated"
347
+ },
348
+ {
349
+ "Key": "aws-cdk:subnet-type",
350
+ "Value": "Isolated"
351
+ },
352
+ {
353
+ "Key": "Name",
354
+ "Value": "lammem-newResources/Vpc/isolatedSubnet1"
355
+ }
356
+ ],
357
+ "VpcId": {
358
+ "Ref": "Vpc8378EB38"
359
+ }
360
+ }
361
+ },
362
+ "VpcisolatedSubnet1RouteTableE442650B": {
363
+ "Type": "AWS::EC2::RouteTable",
364
+ "Properties": {
365
+ "Tags": [
366
+ {
367
+ "Key": "Name",
368
+ "Value": "lammem-newResources/Vpc/isolatedSubnet1"
369
+ }
370
+ ],
371
+ "VpcId": {
372
+ "Ref": "Vpc8378EB38"
373
+ }
374
+ }
375
+ },
376
+ "VpcisolatedSubnet1RouteTableAssociationD259E31A": {
377
+ "Type": "AWS::EC2::SubnetRouteTableAssociation",
378
+ "Properties": {
379
+ "RouteTableId": {
380
+ "Ref": "VpcisolatedSubnet1RouteTableE442650B"
381
+ },
382
+ "SubnetId": {
383
+ "Ref": "VpcisolatedSubnet1SubnetE62B1B9B"
384
+ }
385
+ }
386
+ },
387
+ "VpcisolatedSubnet2Subnet39217055": {
388
+ "Type": "AWS::EC2::Subnet",
389
+ "Properties": {
390
+ "AvailabilityZone": {
391
+ "Fn::Select": [
392
+ 1,
393
+ {
394
+ "Fn::GetAZs": ""
395
+ }
396
+ ]
397
+ },
398
+ "CidrBlock": "10.0.64.0/18",
399
+ "MapPublicIpOnLaunch": false,
400
+ "Tags": [
401
+ {
402
+ "Key": "aws-cdk:subnet-name",
403
+ "Value": "isolated"
404
+ },
405
+ {
406
+ "Key": "aws-cdk:subnet-type",
407
+ "Value": "Isolated"
408
+ },
409
+ {
410
+ "Key": "Name",
411
+ "Value": "lammem-newResources/Vpc/isolatedSubnet2"
412
+ }
413
+ ],
414
+ "VpcId": {
415
+ "Ref": "Vpc8378EB38"
416
+ }
417
+ }
418
+ },
419
+ "VpcisolatedSubnet2RouteTable334F9764": {
420
+ "Type": "AWS::EC2::RouteTable",
421
+ "Properties": {
422
+ "Tags": [
423
+ {
424
+ "Key": "Name",
425
+ "Value": "lammem-newResources/Vpc/isolatedSubnet2"
426
+ }
427
+ ],
428
+ "VpcId": {
429
+ "Ref": "Vpc8378EB38"
430
+ }
431
+ }
432
+ },
433
+ "VpcisolatedSubnet2RouteTableAssociation25A4716F": {
434
+ "Type": "AWS::EC2::SubnetRouteTableAssociation",
435
+ "Properties": {
436
+ "RouteTableId": {
437
+ "Ref": "VpcisolatedSubnet2RouteTable334F9764"
438
+ },
439
+ "SubnetId": {
440
+ "Ref": "VpcisolatedSubnet2Subnet39217055"
441
+ }
442
+ }
443
+ },
444
+ "VpcRestrictDefaultSecurityGroupCustomResourceC73DA2BE": {
445
+ "Type": "Custom::VpcRestrictDefaultSG",
446
+ "Properties": {
447
+ "ServiceToken": {
448
+ "Fn::GetAtt": [
449
+ "CustomVpcRestrictDefaultSGCustomResourceProviderHandlerDC833E5E",
450
+ "Arn"
451
+ ]
452
+ },
453
+ "DefaultSecurityGroupId": {
454
+ "Fn::GetAtt": [
455
+ "Vpc8378EB38",
456
+ "DefaultSecurityGroup"
457
+ ]
458
+ },
459
+ "Account": {
460
+ "Ref": "AWS::AccountId"
461
+ }
462
+ },
463
+ "UpdateReplacePolicy": "Delete",
464
+ "DeletionPolicy": "Delete"
465
+ },
466
+ "VpcFlowLogIAMRole6A475D41": {
467
+ "Type": "AWS::IAM::Role",
468
+ "Properties": {
469
+ "AssumeRolePolicyDocument": {
470
+ "Statement": [
471
+ {
472
+ "Action": "sts:AssumeRole",
473
+ "Effect": "Allow",
474
+ "Principal": {
475
+ "Service": "vpc-flow-logs.amazonaws.com"
476
+ }
477
+ }
478
+ ],
479
+ "Version": "2012-10-17"
480
+ },
481
+ "Tags": [
482
+ {
483
+ "Key": "Name",
484
+ "Value": "lammem-newResources/Vpc/FlowLog"
485
+ }
486
+ ]
487
+ }
488
+ },
489
+ "VpcFlowLogIAMRoleDefaultPolicy406FB995": {
490
+ "Type": "AWS::IAM::Policy",
491
+ "Properties": {
492
+ "PolicyDocument": {
493
+ "Statement": [
494
+ {
495
+ "Action": [
496
+ "logs:CreateLogStream",
497
+ "logs:DescribeLogStreams",
498
+ "logs:PutLogEvents"
499
+ ],
500
+ "Effect": "Allow",
501
+ "Resource": {
502
+ "Fn::GetAtt": [
503
+ "VpcFlowLogLogGroup7B5C56B9",
504
+ "Arn"
505
+ ]
506
+ }
507
+ },
508
+ {
509
+ "Action": "iam:PassRole",
510
+ "Effect": "Allow",
511
+ "Resource": {
512
+ "Fn::GetAtt": [
513
+ "VpcFlowLogIAMRole6A475D41",
514
+ "Arn"
515
+ ]
516
+ }
517
+ }
518
+ ],
519
+ "Version": "2012-10-17"
520
+ },
521
+ "PolicyName": "VpcFlowLogIAMRoleDefaultPolicy406FB995",
522
+ "Roles": [
523
+ {
524
+ "Ref": "VpcFlowLogIAMRole6A475D41"
525
+ }
526
+ ]
527
+ }
528
+ },
529
+ "VpcFlowLogLogGroup7B5C56B9": {
530
+ "Type": "AWS::Logs::LogGroup",
531
+ "Properties": {
532
+ "RetentionInDays": 731,
533
+ "Tags": [
534
+ {
535
+ "Key": "Name",
536
+ "Value": "lammem-newResources/Vpc/FlowLog"
537
+ }
538
+ ]
539
+ },
540
+ "UpdateReplacePolicy": "Retain",
541
+ "DeletionPolicy": "Retain",
542
+ "Metadata": {
543
+ "cfn_nag": {
544
+ "rules_to_suppress": [
545
+ {
546
+ "id": "W84",
547
+ "reason": "By default CloudWatchLogs LogGroups data is encrypted using the CloudWatch server-side encryption keys (AWS Managed Keys)"
548
+ }
549
+ ]
550
+ }
551
+ }
552
+ },
553
+ "VpcFlowLog8FF33A73": {
554
+ "Type": "AWS::EC2::FlowLog",
555
+ "Properties": {
556
+ "DeliverLogsPermissionArn": {
557
+ "Fn::GetAtt": [
558
+ "VpcFlowLogIAMRole6A475D41",
559
+ "Arn"
560
+ ]
561
+ },
562
+ "LogDestinationType": "cloud-watch-logs",
563
+ "LogGroupName": {
564
+ "Ref": "VpcFlowLogLogGroup7B5C56B9"
565
+ },
566
+ "ResourceId": {
567
+ "Ref": "Vpc8378EB38"
568
+ },
569
+ "ResourceType": "VPC",
570
+ "Tags": [
571
+ {
572
+ "Key": "Name",
573
+ "Value": "lammem-newResources/Vpc/FlowLog"
574
+ }
575
+ ],
576
+ "TrafficType": "ALL"
577
+ }
578
+ },
579
+ "CustomVpcRestrictDefaultSGCustomResourceProviderRole26592FE0": {
580
+ "Type": "AWS::IAM::Role",
581
+ "Properties": {
582
+ "AssumeRolePolicyDocument": {
583
+ "Version": "2012-10-17",
584
+ "Statement": [
585
+ {
586
+ "Action": "sts:AssumeRole",
587
+ "Effect": "Allow",
588
+ "Principal": {
589
+ "Service": "lambda.amazonaws.com"
590
+ }
591
+ }
592
+ ]
593
+ },
594
+ "ManagedPolicyArns": [
595
+ {
596
+ "Fn::Sub": "arn:${AWS::Partition}:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole"
597
+ }
598
+ ],
599
+ "Policies": [
600
+ {
601
+ "PolicyName": "Inline",
602
+ "PolicyDocument": {
603
+ "Version": "2012-10-17",
604
+ "Statement": [
605
+ {
606
+ "Effect": "Allow",
607
+ "Action": [
608
+ "ec2:AuthorizeSecurityGroupIngress",
609
+ "ec2:AuthorizeSecurityGroupEgress",
610
+ "ec2:RevokeSecurityGroupIngress",
611
+ "ec2:RevokeSecurityGroupEgress"
612
+ ],
613
+ "Resource": [
614
+ {
615
+ "Fn::Join": [
616
+ "",
617
+ [
618
+ "arn:",
619
+ {
620
+ "Ref": "AWS::Partition"
621
+ },
622
+ ":ec2:",
623
+ {
624
+ "Ref": "AWS::Region"
625
+ },
626
+ ":",
627
+ {
628
+ "Ref": "AWS::AccountId"
629
+ },
630
+ ":security-group/",
631
+ {
632
+ "Fn::GetAtt": [
633
+ "Vpc8378EB38",
634
+ "DefaultSecurityGroup"
635
+ ]
636
+ }
637
+ ]
638
+ ]
639
+ }
640
+ ]
641
+ }
642
+ ]
643
+ }
644
+ }
645
+ ]
646
+ }
647
+ },
648
+ "CustomVpcRestrictDefaultSGCustomResourceProviderHandlerDC833E5E": {
649
+ "Type": "AWS::Lambda::Function",
650
+ "Properties": {
651
+ "Code": {
652
+ "S3Bucket": {
653
+ "Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
654
+ },
655
+ "S3Key": "dd5711540f04e06aa955d7f4862fc04e8cdea464cb590dae91ed2976bb78098e.zip"
656
+ },
657
+ "Timeout": 900,
658
+ "MemorySize": 128,
659
+ "Handler": "__entrypoint__.handler",
660
+ "Role": {
661
+ "Fn::GetAtt": [
662
+ "CustomVpcRestrictDefaultSGCustomResourceProviderRole26592FE0",
663
+ "Arn"
664
+ ]
665
+ },
666
+ "Runtime": "nodejs18.x",
667
+ "Description": "Lambda function for removing all inbound/outbound rules from the VPC default security group"
668
+ },
669
+ "DependsOn": [
670
+ "CustomVpcRestrictDefaultSGCustomResourceProviderRole26592FE0"
671
+ ],
672
+ "Metadata": {
673
+ "cfn_nag": {
674
+ "rules_to_suppress": [
675
+ {
676
+ "id": "W58",
677
+ "reason": "CDK generated custom resource"
678
+ },
679
+ {
680
+ "id": "W89",
681
+ "reason": "CDK generated custom resource"
682
+ },
683
+ {
684
+ "id": "W92",
685
+ "reason": "CDK generated custom resource"
686
+ }
687
+ ]
688
+ }
689
+ }
690
+ }
691
+ },
692
+ "Parameters": {
693
+ "BootstrapVersion": {
694
+ "Type": "AWS::SSM::Parameter::Value<String>",
695
+ "Default": "/cdk-bootstrap/hnb659fds/version",
696
+ "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]"
697
+ }
698
+ },
699
+ "Rules": {
700
+ "CheckBootstrapVersion": {
701
+ "Assertions": [
702
+ {
703
+ "Assert": {
704
+ "Fn::Not": [
705
+ {
706
+ "Fn::Contains": [
707
+ [
708
+ "1",
709
+ "2",
710
+ "3",
711
+ "4",
712
+ "5"
713
+ ],
714
+ {
715
+ "Ref": "BootstrapVersion"
716
+ }
717
+ ]
718
+ }
719
+ ]
720
+ },
721
+ "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI."
722
+ }
723
+ ]
724
+ }
725
+ }
726
+ }