@gradientedge/cdk-utils 4.3.2 → 4.4.3
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.
- package/README.md +39 -28
- package/api-docs/AcmManager.html +622 -0
- package/api-docs/AcmProps.html +238 -0
- package/api-docs/AlarmProps.html +238 -0
- package/api-docs/AlarmStatusWidgetProps.html +238 -0
- package/api-docs/ApiDestinationEvent.html +297 -0
- package/api-docs/ApiDestinationEventType.html +238 -0
- package/api-docs/ApiDestinedLambda.html +297 -0
- package/api-docs/ApiDestinedLambdaEnvironment.html +238 -0
- package/api-docs/ApiDestinedLambdaType.html +238 -0
- package/api-docs/ApiDestinedRestApi.html +297 -0
- package/api-docs/ApiDestinedRestApiType.html +238 -0
- package/api-docs/ApiManager.html +766 -0
- package/api-docs/ApiToEventBridgeTarget.html +1877 -0
- package/api-docs/ApiToEventBridgeTarget.jpg +0 -0
- package/api-docs/ApiToEventBridgeTargetEventProps.html +238 -0
- package/api-docs/ApiToEventBridgeTargetLambdaProps.html +238 -0
- package/api-docs/ApiToEventBridgeTargetProps.html +238 -0
- package/api-docs/ApiToEventBridgeTargetRestApiProps.html +238 -0
- package/api-docs/AppConfigManager.html +1203 -0
- package/api-docs/AppConfigProps.html +238 -0
- package/api-docs/CloudFrontManager.html +2402 -0
- package/api-docs/CloudFrontProps.html +238 -0
- package/api-docs/CloudTrailManager.html +637 -0
- package/api-docs/CloudTrailProps.html +238 -0
- package/api-docs/CloudWatchManager.html +2986 -0
- package/api-docs/CloudfrontFunctionProps.html +238 -0
- package/api-docs/CodeBuildManager.html +736 -0
- package/api-docs/CommonConstruct.html +1299 -0
- package/api-docs/CommonStack.html +813 -0
- package/api-docs/CommonStackProps.html +238 -0
- package/api-docs/DashboardProps.html +238 -0
- package/api-docs/DistributionProps.html +238 -0
- package/api-docs/DynamodbManager.html +530 -0
- package/api-docs/EcrManager.html +530 -0
- package/api-docs/EcsClusterProps.html +238 -0
- package/api-docs/EcsManager.html +880 -0
- package/api-docs/EcsTaskProps.html +238 -0
- package/api-docs/EksClusterProps.html +238 -0
- package/api-docs/EksManager.html +580 -0
- package/api-docs/EventBusProps.html +238 -0
- package/api-docs/EventManager.html +1454 -0
- package/api-docs/EventRuleProps.html +238 -0
- package/api-docs/GraphQLApiLambda.html +1671 -0
- package/api-docs/GraphQLApiLambda.jpg +0 -0
- package/api-docs/GraphQlApiLambdaEnvironment.html +238 -0
- package/api-docs/GraphQlApiLambdaProps.html +238 -0
- package/api-docs/GraphWidgetProps.html +238 -0
- package/api-docs/HealthCheck.html +238 -0
- package/api-docs/IamManager.html +3821 -0
- package/api-docs/LambdaEdgeProps.html +238 -0
- package/api-docs/LambdaEnvironment.html +238 -0
- package/api-docs/LambdaManager.html +2378 -0
- package/api-docs/LambdaProps.html +238 -0
- package/api-docs/LifecycleRule.html +238 -0
- package/api-docs/LogManager.html +955 -0
- package/api-docs/LogProps.html +238 -0
- package/api-docs/LogQueryWidgetProps.html +238 -0
- package/api-docs/MetricFilterProps.html +238 -0
- package/api-docs/MetricProps.html +238 -0
- package/api-docs/NumericWidgetProps.html +238 -0
- package/api-docs/Route53Manager.html +1460 -0
- package/api-docs/Route53Props.html +238 -0
- package/api-docs/RuleProps.html +238 -0
- package/api-docs/S3BucketProps.html +238 -0
- package/api-docs/S3Manager.html +1546 -0
- package/api-docs/SSMParameterReader.html +431 -0
- package/api-docs/SSMParameterReaderProps.html +238 -0
- package/api-docs/SecretsManager.html +1140 -0
- package/api-docs/SiteWithEcsBackend.html +2391 -0
- package/api-docs/SiteWithEcsBackendProps.html +238 -0
- package/api-docs/SnsManager.html +780 -0
- package/api-docs/SsmManager.html +955 -0
- package/api-docs/StaticSite.html +1358 -0
- package/api-docs/StaticSiteProps.html +238 -0
- package/api-docs/SubscriptionProps.html +238 -0
- package/api-docs/TableProps.html +238 -0
- package/api-docs/TextWidgetProps.html +238 -0
- package/api-docs/VpcManager.html +986 -0
- package/api-docs/WafIPSetProps.html +238 -0
- package/api-docs/WafManager.html +730 -0
- package/api-docs/WafWebACLProps.html +238 -0
- package/api-docs/common_construct.ts.html +279 -0
- package/api-docs/common_stack.ts.html +303 -0
- package/api-docs/construct_api-to-eventbridge-target_api-destination-event.ts.html +175 -0
- package/api-docs/construct_api-to-eventbridge-target_api-destined-lambda.ts.html +178 -0
- package/api-docs/construct_api-to-eventbridge-target_api-destined-rest-api.ts.html +190 -0
- package/api-docs/construct_api-to-eventbridge-target_main.ts.html +751 -0
- package/api-docs/construct_graphql-api-lambda_main.ts.html +408 -0
- package/api-docs/construct_site-with-ecs-backend_main.ts.html +544 -0
- package/api-docs/construct_static-site_main.ts.html +374 -0
- package/api-docs/global.html +1530 -0
- package/api-docs/index.html +208 -0
- package/api-docs/logo.png +0 -0
- package/api-docs/manager_aws_acm-manager.ts.html +236 -0
- package/api-docs/manager_aws_api-manager.ts.html +260 -0
- package/api-docs/manager_aws_app-config-manager.ts.html +310 -0
- package/api-docs/manager_aws_cloudfront-manager.ts.html +491 -0
- package/api-docs/manager_aws_cloudtrail-manager.ts.html +251 -0
- package/api-docs/manager_aws_cloudwatch-manager.ts.html +553 -0
- package/api-docs/manager_aws_codebuild-manager.ts.html +240 -0
- package/api-docs/manager_aws_dynamodb-manager.ts.html +219 -0
- package/api-docs/manager_aws_ecr-manager.ts.html +199 -0
- package/api-docs/manager_aws_ecs-manager.ts.html +259 -0
- package/api-docs/manager_aws_eks-manager.ts.html +260 -0
- package/api-docs/manager_aws_event-manager.ts.html +336 -0
- package/api-docs/manager_aws_iam-manager.ts.html +573 -0
- package/api-docs/manager_aws_lambda-manager.ts.html +400 -0
- package/api-docs/manager_aws_log-manager.ts.html +259 -0
- package/api-docs/manager_aws_route53-manager.ts.html +333 -0
- package/api-docs/manager_aws_s3-manager.ts.html +361 -0
- package/api-docs/manager_aws_secrets-manager.ts.html +274 -0
- package/api-docs/manager_aws_sns-manager.ts.html +246 -0
- package/api-docs/manager_aws_ssm-manager.ts.html +273 -0
- package/api-docs/manager_aws_vpc-manager.ts.html +244 -0
- package/api-docs/manager_aws_waf-manager.ts.html +232 -0
- package/api-docs/scripts/app.min.js +1 -0
- package/api-docs/scripts/linenumber.js +26 -0
- package/api-docs/scripts/search.js +39 -0
- package/api-docs/styles/app.min.css +1 -0
- package/api-docs/styles/iframe.css +13 -0
- package/api-docs/styles/prettify-jsdoc.css +111 -0
- package/api-docs/styles/prettify-tomorrow.css +132 -0
- package/api-docs/styles/reset.css +44 -0
- package/api-docs/styles.css +113 -0
- package/api-docs/tutorial-Architecture.html +151 -0
- package/api-docs/tutorial-Build.html +150 -0
- package/api-docs/tutorial-CI-CD.html +154 -0
- package/api-docs/tutorial-Development.html +227 -0
- package/api-docs/types_aws_index.ts.html +665 -0
- package/api-docs/utils_aws_index.ts.html +192 -0
- package/api-docs/utils_index.ts.html +227 -0
- package/app/api-destined-function/node_modules/.yarn-integrity +180 -0
- package/app/api-destined-function/node_modules/@types/uuid/LICENSE +21 -0
- package/app/api-destined-function/node_modules/@types/uuid/README.md +16 -0
- package/app/api-destined-function/node_modules/@types/uuid/index.d.mts +10 -0
- package/app/api-destined-function/node_modules/@types/uuid/index.d.ts +80 -0
- package/app/api-destined-function/node_modules/@types/uuid/package.json +54 -0
- package/app/api-destined-function/node_modules/balanced-match/LICENSE.md +21 -0
- package/app/api-destined-function/node_modules/balanced-match/README.md +97 -0
- package/app/api-destined-function/node_modules/balanced-match/index.js +62 -0
- package/app/api-destined-function/node_modules/balanced-match/package.json +48 -0
- package/app/api-destined-function/node_modules/brace-expansion/LICENSE +21 -0
- package/app/api-destined-function/node_modules/brace-expansion/README.md +129 -0
- package/app/api-destined-function/node_modules/brace-expansion/index.js +201 -0
- package/app/api-destined-function/node_modules/brace-expansion/package.json +47 -0
- package/app/api-destined-function/node_modules/concat-map/.travis.yml +4 -0
- package/app/api-destined-function/node_modules/concat-map/LICENSE +18 -0
- package/app/api-destined-function/node_modules/concat-map/README.markdown +62 -0
- package/app/api-destined-function/node_modules/concat-map/example/map.js +6 -0
- package/app/api-destined-function/node_modules/concat-map/index.js +13 -0
- package/app/api-destined-function/node_modules/concat-map/package.json +43 -0
- package/app/api-destined-function/node_modules/fs.realpath/LICENSE +43 -0
- package/app/api-destined-function/node_modules/fs.realpath/README.md +33 -0
- package/app/api-destined-function/node_modules/fs.realpath/index.js +66 -0
- package/app/api-destined-function/node_modules/fs.realpath/old.js +303 -0
- package/app/api-destined-function/node_modules/fs.realpath/package.json +26 -0
- package/app/api-destined-function/node_modules/glob/LICENSE +21 -0
- package/app/api-destined-function/node_modules/glob/README.md +378 -0
- package/app/api-destined-function/node_modules/glob/common.js +236 -0
- package/app/api-destined-function/node_modules/glob/glob.js +787 -0
- package/app/api-destined-function/node_modules/glob/package.json +52 -0
- package/app/api-destined-function/node_modules/glob/sync.js +483 -0
- package/app/api-destined-function/node_modules/inflight/LICENSE +15 -0
- package/app/api-destined-function/node_modules/inflight/README.md +37 -0
- package/app/api-destined-function/node_modules/inflight/inflight.js +54 -0
- package/app/api-destined-function/node_modules/inflight/package.json +29 -0
- package/app/api-destined-function/node_modules/inherits/LICENSE +16 -0
- package/app/api-destined-function/node_modules/inherits/README.md +42 -0
- package/app/api-destined-function/node_modules/inherits/inherits.js +9 -0
- package/app/api-destined-function/node_modules/inherits/inherits_browser.js +27 -0
- package/app/api-destined-function/node_modules/inherits/package.json +29 -0
- package/app/api-destined-function/node_modules/minimatch/LICENSE +15 -0
- package/app/api-destined-function/node_modules/minimatch/README.md +209 -0
- package/app/api-destined-function/node_modules/minimatch/minimatch.js +923 -0
- package/app/api-destined-function/node_modules/minimatch/package.json +30 -0
- package/app/api-destined-function/node_modules/mkdirp/LICENSE +21 -0
- package/app/api-destined-function/node_modules/mkdirp/bin/cmd.js +68 -0
- package/app/api-destined-function/node_modules/mkdirp/index.js +31 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/find-made.js +29 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/mkdirp-manual.js +64 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/mkdirp-native.js +39 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/opts-arg.js +23 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/path-arg.js +29 -0
- package/app/api-destined-function/node_modules/mkdirp/lib/use-native.js +10 -0
- package/app/api-destined-function/node_modules/mkdirp/package.json +44 -0
- package/app/api-destined-function/node_modules/mkdirp/readme.markdown +266 -0
- package/app/api-destined-function/node_modules/once/LICENSE +15 -0
- package/app/api-destined-function/node_modules/once/README.md +79 -0
- package/app/api-destined-function/node_modules/once/once.js +42 -0
- package/app/api-destined-function/node_modules/once/package.json +33 -0
- package/app/api-destined-function/node_modules/path-is-absolute/index.js +20 -0
- package/app/api-destined-function/node_modules/path-is-absolute/license +21 -0
- package/app/api-destined-function/node_modules/path-is-absolute/package.json +43 -0
- package/app/api-destined-function/node_modules/path-is-absolute/readme.md +59 -0
- package/app/api-destined-function/node_modules/rimraf/LICENSE +15 -0
- package/app/api-destined-function/node_modules/rimraf/README.md +101 -0
- package/app/api-destined-function/node_modules/rimraf/bin.js +68 -0
- package/app/api-destined-function/node_modules/rimraf/package.json +32 -0
- package/app/api-destined-function/node_modules/rimraf/rimraf.js +360 -0
- package/app/api-destined-function/node_modules/uuid/LICENSE.md +9 -0
- package/app/api-destined-function/node_modules/uuid/README.md +505 -0
- package/app/api-destined-function/node_modules/uuid/package.json +135 -0
- package/app/api-destined-function/node_modules/uuid/wrapper.mjs +10 -0
- package/app/api-destined-function/node_modules/wrappy/LICENSE +15 -0
- package/app/api-destined-function/node_modules/wrappy/README.md +36 -0
- package/app/api-destined-function/node_modules/wrappy/package.json +29 -0
- package/app/api-destined-function/node_modules/wrappy/wrappy.js +33 -0
- package/app/api-destined-function/package.json +29 -0
- package/app/api-destined-function/src/lib/lambda.ts +31 -0
- package/img/ApiToEventBridgeTarget.jpg +0 -0
- package/img/GraphQLApiLambda.jpg +0 -0
- package/img/logo.png +0 -0
- package/package.json +17 -18
- package/src/lib/common/{commonConstruct.ts → construct.ts} +3 -13
- package/src/lib/common/index.ts +2 -2
- package/src/lib/common/{commonStack.ts → stack.ts} +5 -14
- package/src/lib/construct/api-to-eventbridge-target/api-destination-event.ts +17 -0
- package/src/lib/construct/api-to-eventbridge-target/api-destined-lambda.ts +20 -0
- package/src/lib/construct/api-to-eventbridge-target/api-destined-rest-api.ts +32 -0
- package/src/lib/construct/api-to-eventbridge-target/index.ts +4 -0
- package/src/lib/construct/api-to-eventbridge-target/main.ts +593 -0
- package/src/lib/construct/graphql-api-lambda/index.ts +1 -0
- package/src/lib/construct/{graphQLApiLambda.ts → graphql-api-lambda/main.ts} +11 -20
- package/src/lib/construct/index.ts +4 -3
- package/src/lib/construct/site-with-ecs-backend/index.ts +1 -0
- package/src/lib/construct/{siteWithEcsBackend.ts → site-with-ecs-backend/main.ts} +6 -17
- package/src/lib/construct/static-site/index.ts +1 -0
- package/src/lib/construct/{staticSite.ts → static-site/main.ts} +5 -16
- package/src/lib/manager/aws/{acmManager.ts → acm-manager.ts} +3 -2
- package/src/lib/manager/aws/{apiManager.ts → api-manager.ts} +6 -5
- package/src/lib/manager/aws/{appConfigManager.ts → app-config-manager.ts} +5 -3
- package/src/lib/manager/aws/{cloudFrontManager.ts → cloudfront-manager.ts} +3 -2
- package/src/lib/manager/aws/{cloudTrailManager.ts → cloudtrail-manager.ts} +3 -2
- package/src/lib/manager/aws/{cloudWatchManager.ts → cloudwatch-manager.ts} +5 -3
- package/src/lib/manager/aws/{codeBuildManager.ts → codebuild-manager.ts} +3 -2
- package/src/lib/manager/aws/{dynamodbManager.ts → dynamodb-manager.ts} +3 -2
- package/src/lib/manager/aws/{ecrManager.ts → ecr-manager.ts} +3 -2
- package/src/lib/manager/aws/{ecsManager.ts → ecs-manager.ts} +3 -2
- package/src/lib/manager/aws/{eksManager.ts → eks-manager.ts} +3 -2
- package/src/lib/manager/aws/{eventManager.ts → event-manager.ts} +57 -2
- package/src/lib/manager/aws/{iamManager.ts → iam-manager.ts} +23 -17
- package/src/lib/manager/aws/index.ts +22 -22
- package/src/lib/manager/aws/{lambdaManager.ts → lambda-manager.ts} +4 -3
- package/src/lib/manager/aws/{logManager.ts → log-manager.ts} +3 -2
- package/src/lib/manager/aws/{route53Manager.ts → route53-manager.ts} +4 -3
- package/src/lib/manager/aws/{s3Manager.ts → s3-manager.ts} +3 -2
- package/src/lib/manager/aws/{secretsManager.ts → secrets-manager.ts} +3 -2
- package/src/lib/manager/aws/{snsManager.ts → sns-manager.ts} +3 -2
- package/src/lib/manager/aws/{ssmManager.ts → ssm-manager.ts} +6 -9
- package/src/lib/manager/aws/{vpcManager.ts → vpc-manager.ts} +8 -5
- package/src/lib/manager/aws/{wafManager.ts → waf-manager.ts} +3 -2
- package/src/lib/types/aws/index.ts +221 -32
- package/src/lib/utils/aws/index.ts +2 -2
- package/src/lib/utils/index.ts +8 -8
- package/theme/styles.css +113 -0
- package/.releaserc +0 -9
- package/dist/index.d.ts +0 -6
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/src/lib/common/commonConstruct.d.ts +0 -90
- package/dist/src/lib/common/commonConstruct.d.ts.map +0 -1
- package/dist/src/lib/common/commonConstruct.js +0 -144
- package/dist/src/lib/common/commonConstruct.js.map +0 -1
- package/dist/src/lib/common/commonStack.d.ts +0 -65
- package/dist/src/lib/common/commonStack.d.ts.map +0 -1
- package/dist/src/lib/common/commonStack.js +0 -158
- package/dist/src/lib/common/commonStack.js.map +0 -1
- package/dist/src/lib/common/index.d.ts +0 -3
- package/dist/src/lib/common/index.d.ts.map +0 -1
- package/dist/src/lib/common/index.js +0 -15
- package/dist/src/lib/common/index.js.map +0 -1
- package/dist/src/lib/construct/graphQLApiLambda.d.ts +0 -122
- package/dist/src/lib/construct/graphQLApiLambda.d.ts.map +0 -1
- package/dist/src/lib/construct/graphQLApiLambda.js +0 -211
- package/dist/src/lib/construct/graphQLApiLambda.js.map +0 -1
- package/dist/src/lib/construct/index.d.ts +0 -4
- package/dist/src/lib/construct/index.d.ts.map +0 -1
- package/dist/src/lib/construct/index.js +0 -16
- package/dist/src/lib/construct/index.js.map +0 -1
- package/dist/src/lib/construct/siteWithEcsBackend.d.ts +0 -179
- package/dist/src/lib/construct/siteWithEcsBackend.d.ts.map +0 -1
- package/dist/src/lib/construct/siteWithEcsBackend.js +0 -339
- package/dist/src/lib/construct/siteWithEcsBackend.js.map +0 -1
- package/dist/src/lib/construct/staticSite.d.ts +0 -106
- package/dist/src/lib/construct/staticSite.d.ts.map +0 -1
- package/dist/src/lib/construct/staticSite.js +0 -180
- package/dist/src/lib/construct/staticSite.js.map +0 -1
- package/dist/src/lib/manager/aws/acmManager.d.ts +0 -46
- package/dist/src/lib/manager/aws/acmManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/acmManager.js +0 -90
- package/dist/src/lib/manager/aws/acmManager.js.map +0 -1
- package/dist/src/lib/manager/aws/apiManager.d.ts +0 -43
- package/dist/src/lib/manager/aws/apiManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/apiManager.js +0 -111
- package/dist/src/lib/manager/aws/apiManager.js.map +0 -1
- package/dist/src/lib/manager/aws/appConfigManager.d.ts +0 -64
- package/dist/src/lib/manager/aws/appConfigManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/appConfigManager.js +0 -147
- package/dist/src/lib/manager/aws/appConfigManager.js.map +0 -1
- package/dist/src/lib/manager/aws/cloudFrontManager.d.ts +0 -112
- package/dist/src/lib/manager/aws/cloudFrontManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/cloudFrontManager.js +0 -282
- package/dist/src/lib/manager/aws/cloudFrontManager.js.map +0 -1
- package/dist/src/lib/manager/aws/cloudTrailManager.d.ts +0 -48
- package/dist/src/lib/manager/aws/cloudTrailManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/cloudTrailManager.js +0 -99
- package/dist/src/lib/manager/aws/cloudTrailManager.js.map +0 -1
- package/dist/src/lib/manager/aws/cloudWatchManager.d.ts +0 -121
- package/dist/src/lib/manager/aws/cloudWatchManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/cloudWatchManager.js +0 -351
- package/dist/src/lib/manager/aws/cloudWatchManager.js.map +0 -1
- package/dist/src/lib/manager/aws/codeBuildManager.d.ts +0 -40
- package/dist/src/lib/manager/aws/codeBuildManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/codeBuildManager.js +0 -94
- package/dist/src/lib/manager/aws/codeBuildManager.js.map +0 -1
- package/dist/src/lib/manager/aws/dynamodbManager.d.ts +0 -32
- package/dist/src/lib/manager/aws/dynamodbManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/dynamodbManager.js +0 -79
- package/dist/src/lib/manager/aws/dynamodbManager.js.map +0 -1
- package/dist/src/lib/manager/aws/ecrManager.d.ts +0 -31
- package/dist/src/lib/manager/aws/ecrManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/ecrManager.js +0 -60
- package/dist/src/lib/manager/aws/ecrManager.js.map +0 -1
- package/dist/src/lib/manager/aws/ecsManager.d.ts +0 -48
- package/dist/src/lib/manager/aws/ecsManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/ecsManager.js +0 -103
- package/dist/src/lib/manager/aws/ecsManager.js.map +0 -1
- package/dist/src/lib/manager/aws/eksManager.d.ts +0 -36
- package/dist/src/lib/manager/aws/eksManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/eksManager.js +0 -109
- package/dist/src/lib/manager/aws/eksManager.js.map +0 -1
- package/dist/src/lib/manager/aws/eventManager.d.ts +0 -51
- package/dist/src/lib/manager/aws/eventManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/eventManager.js +0 -120
- package/dist/src/lib/manager/aws/eventManager.js.map +0 -1
- package/dist/src/lib/manager/aws/iamManager.d.ts +0 -156
- package/dist/src/lib/manager/aws/iamManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/iamManager.js +0 -376
- package/dist/src/lib/manager/aws/iamManager.js.map +0 -1
- package/dist/src/lib/manager/aws/index.d.ts +0 -23
- package/dist/src/lib/manager/aws/index.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/index.js +0 -35
- package/dist/src/lib/manager/aws/index.js.map +0 -1
- package/dist/src/lib/manager/aws/lambdaManager.d.ts +0 -94
- package/dist/src/lib/manager/aws/lambdaManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/lambdaManager.js +0 -196
- package/dist/src/lib/manager/aws/lambdaManager.js.map +0 -1
- package/dist/src/lib/manager/aws/logManager.d.ts +0 -51
- package/dist/src/lib/manager/aws/logManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/logManager.js +0 -108
- package/dist/src/lib/manager/aws/logManager.js.map +0 -1
- package/dist/src/lib/manager/aws/route53Manager.d.ts +0 -68
- package/dist/src/lib/manager/aws/route53Manager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/route53Manager.js +0 -158
- package/dist/src/lib/manager/aws/route53Manager.js.map +0 -1
- package/dist/src/lib/manager/aws/s3Manager.d.ts +0 -73
- package/dist/src/lib/manager/aws/s3Manager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/s3Manager.js +0 -202
- package/dist/src/lib/manager/aws/s3Manager.js.map +0 -1
- package/dist/src/lib/manager/aws/secretsManager.d.ts +0 -57
- package/dist/src/lib/manager/aws/secretsManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/secretsManager.js +0 -116
- package/dist/src/lib/manager/aws/secretsManager.js.map +0 -1
- package/dist/src/lib/manager/aws/snsManager.d.ts +0 -42
- package/dist/src/lib/manager/aws/snsManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/snsManager.js +0 -90
- package/dist/src/lib/manager/aws/snsManager.js.map +0 -1
- package/dist/src/lib/manager/aws/ssmManager.d.ts +0 -64
- package/dist/src/lib/manager/aws/ssmManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/ssmManager.js +0 -128
- package/dist/src/lib/manager/aws/ssmManager.js.map +0 -1
- package/dist/src/lib/manager/aws/vpcManager.d.ts +0 -44
- package/dist/src/lib/manager/aws/vpcManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/vpcManager.js +0 -92
- package/dist/src/lib/manager/aws/vpcManager.js.map +0 -1
- package/dist/src/lib/manager/aws/wafManager.d.ts +0 -39
- package/dist/src/lib/manager/aws/wafManager.d.ts.map +0 -1
- package/dist/src/lib/manager/aws/wafManager.js +0 -89
- package/dist/src/lib/manager/aws/wafManager.js.map +0 -1
- package/dist/src/lib/manager/index.d.ts +0 -2
- package/dist/src/lib/manager/index.d.ts.map +0 -1
- package/dist/src/lib/manager/index.js +0 -14
- package/dist/src/lib/manager/index.js.map +0 -1
- package/dist/src/lib/types/aws/index.d.ts +0 -294
- package/dist/src/lib/types/aws/index.d.ts.map +0 -1
- package/dist/src/lib/types/aws/index.js +0 -3
- package/dist/src/lib/types/aws/index.js.map +0 -1
- package/dist/src/lib/types/index.d.ts +0 -2
- package/dist/src/lib/types/index.d.ts.map +0 -1
- package/dist/src/lib/types/index.js +0 -14
- package/dist/src/lib/types/index.js.map +0 -1
- package/dist/src/lib/utils/aws/index.d.ts +0 -16
- package/dist/src/lib/utils/aws/index.d.ts.map +0 -1
- package/dist/src/lib/utils/aws/index.js +0 -50
- package/dist/src/lib/utils/aws/index.js.map +0 -1
- package/dist/src/lib/utils/index.d.ts +0 -63
- package/dist/src/lib/utils/index.d.ts.map +0 -1
- package/dist/src/lib/utils/index.js +0 -85
- package/dist/src/lib/utils/index.js.map +0 -1
package/dist/index.d.ts
DELETED
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAA;AAChC,cAAc,qBAAqB,CAAA;AACnC,cAAc,mBAAmB,CAAA;AACjC,cAAc,iBAAiB,CAAA;AAC/B,cAAc,iBAAiB,CAAA"}
|
package/dist/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mDAAgC;AAChC,sDAAmC;AACnC,oDAAiC;AACjC,kDAA+B;AAC/B,kDAA+B"}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
import * as cdk from 'aws-cdk-lib';
|
|
2
|
-
import { Construct } from 'constructs';
|
|
3
|
-
import * as aws from '../manager/aws';
|
|
4
|
-
import * as types from '../types';
|
|
5
|
-
/**
|
|
6
|
-
* @stability stable
|
|
7
|
-
* @category Constructs
|
|
8
|
-
* @summary Common construct to use as a base for all higher level constructs.
|
|
9
|
-
*
|
|
10
|
-
* @example
|
|
11
|
-
* import { CommonConstruct } from '@gradientedge/cdk-utils';
|
|
12
|
-
*
|
|
13
|
-
* class CustomConstruct extends CommonConstruct {
|
|
14
|
-
* constructor(parent: cdk.Construct, id: string, props: common.CommonStackProps) {
|
|
15
|
-
* super(parent, id, props);
|
|
16
|
-
* this.props = props;
|
|
17
|
-
* };
|
|
18
|
-
* };
|
|
19
|
-
*
|
|
20
|
-
* @mermaid
|
|
21
|
-
* graph LR;
|
|
22
|
-
* A[CommonConstruct]-.->|extends|B(Construct);
|
|
23
|
-
* B(Construct)-->|implements|C(IConstruct);
|
|
24
|
-
*/
|
|
25
|
-
export declare class CommonConstruct extends Construct {
|
|
26
|
-
props: types.CommonStackProps;
|
|
27
|
-
acmManager: aws.AcmManager;
|
|
28
|
-
apiManager: aws.ApiManager;
|
|
29
|
-
appConfigManager: aws.AppConfigManager;
|
|
30
|
-
codeBuildManager: aws.CodeBuildManager;
|
|
31
|
-
cloudFrontManager: aws.CloudFrontManager;
|
|
32
|
-
cloudTrailManager: aws.CloudTrailManager;
|
|
33
|
-
cloudWatchManager: aws.CloudWatchManager;
|
|
34
|
-
dynamodbManager: aws.DynamodbManager;
|
|
35
|
-
ecrManager: aws.EcrManager;
|
|
36
|
-
ecsManager: aws.EcsManager;
|
|
37
|
-
eksManager: aws.EksManager;
|
|
38
|
-
eventManager: aws.EventManager;
|
|
39
|
-
iamManager: aws.IamManager;
|
|
40
|
-
lambdaManager: aws.LambdaManager;
|
|
41
|
-
logManager: aws.LogManager;
|
|
42
|
-
route53Manager: aws.Route53Manager;
|
|
43
|
-
s3Manager: aws.S3Manager;
|
|
44
|
-
secretsManager: aws.SecretsManager;
|
|
45
|
-
snsManager: aws.SnsManager;
|
|
46
|
-
ssMManager: aws.SsmManager;
|
|
47
|
-
vpcManager: aws.VpcManager;
|
|
48
|
-
wafManager: aws.WafManager;
|
|
49
|
-
fullyQualifiedDomainName: string;
|
|
50
|
-
/**
|
|
51
|
-
* @summary Constructor to initialise the CommonConstruct
|
|
52
|
-
* @param {Construct} parent
|
|
53
|
-
* @param {string} id scoped id of the resource
|
|
54
|
-
* @param {CommonStackProps} props
|
|
55
|
-
*/
|
|
56
|
-
constructor(parent: Construct, id: string, props: types.CommonStackProps);
|
|
57
|
-
/**
|
|
58
|
-
* @summary Helper method to add CloudFormation outputs from the construct
|
|
59
|
-
* @param {string} id scoped id of the resource
|
|
60
|
-
* @param {string} value the value of the exported output
|
|
61
|
-
* @param {string?} description optional description for the output
|
|
62
|
-
* @param {boolean} overrideId Flag which indicates whether to override the default logical id of the output
|
|
63
|
-
*/
|
|
64
|
-
protected addCfnOutput(id: string, value: string, description?: string, overrideId?: boolean): cdk.CfnOutput;
|
|
65
|
-
/**
|
|
66
|
-
* @summary Determine the fully qualified domain name based on domainName & subDomain
|
|
67
|
-
*/
|
|
68
|
-
protected determineFullyQualifiedDomain(): void;
|
|
69
|
-
/**
|
|
70
|
-
* @summary Utility method to determine if the initialisation is in development (dev) stage
|
|
71
|
-
* This is determined by the stage property injected via cdk context
|
|
72
|
-
*/
|
|
73
|
-
isDevelopmentStage: () => boolean;
|
|
74
|
-
/**
|
|
75
|
-
* @summary Utility method to determine if the initialisation is in test (tst) stage
|
|
76
|
-
* This is determined by the stage property injected via cdk context
|
|
77
|
-
*/
|
|
78
|
-
isTestStage: () => boolean;
|
|
79
|
-
/**
|
|
80
|
-
* @summary Utility method to determine if the initialisation is in uat (uat) stage
|
|
81
|
-
* This is determined by the stage property injected via cdk context
|
|
82
|
-
*/
|
|
83
|
-
isUatStage: () => boolean;
|
|
84
|
-
/**
|
|
85
|
-
* @summary Utility method to determine if the initialisation is in production (prd) stage
|
|
86
|
-
* This is determined by the stage property injected via cdk context
|
|
87
|
-
*/
|
|
88
|
-
isProductionStage: () => boolean;
|
|
89
|
-
}
|
|
90
|
-
//# sourceMappingURL=commonConstruct.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commonConstruct.d.ts","sourceRoot":"","sources":["../../../../src/lib/common/commonConstruct.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,GAAG,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAA;AACtC,OAAO,KAAK,GAAG,MAAM,gBAAgB,CAAA;AACrC,OAAO,KAAK,KAAK,MAAM,UAAU,CAAA;AAGjC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,qBAAa,eAAgB,SAAQ,SAAS;IAC5C,KAAK,EAAE,KAAK,CAAC,gBAAgB,CAAA;IAC7B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,gBAAgB,EAAE,GAAG,CAAC,gBAAgB,CAAA;IACtC,gBAAgB,EAAE,GAAG,CAAC,gBAAgB,CAAA;IACtC,iBAAiB,EAAE,GAAG,CAAC,iBAAiB,CAAA;IACxC,iBAAiB,EAAE,GAAG,CAAC,iBAAiB,CAAA;IACxC,iBAAiB,EAAE,GAAG,CAAC,iBAAiB,CAAA;IACxC,eAAe,EAAE,GAAG,CAAC,eAAe,CAAA;IACpC,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,YAAY,EAAE,GAAG,CAAC,YAAY,CAAA;IAC9B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,aAAa,EAAE,GAAG,CAAC,aAAa,CAAA;IAChC,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,cAAc,EAAE,GAAG,CAAC,cAAc,CAAA;IAClC,SAAS,EAAE,GAAG,CAAC,SAAS,CAAA;IACxB,cAAc,EAAE,GAAG,CAAC,cAAc,CAAA;IAClC,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAA;IAC1B,wBAAwB,EAAE,MAAM,CAAA;IAEhC;;;;;OAKG;gBACS,MAAM,EAAE,SAAS,EAAE,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,CAAC,gBAAgB;IA6BxE;;;;;;OAMG;IACH,SAAS,CAAC,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,MAAM,EAAE,UAAU,UAAO,GAAG,GAAG,CAAC,SAAS;IAIzG;;OAEG;IACH,SAAS,CAAC,6BAA6B;IAMvC;;;OAGG;IACI,kBAAkB,gBAA2C;IAEpE;;;OAGG;IACI,WAAW,gBAA4C;IAE9D;;;OAGG;IACI,UAAU,gBAA2C;IAE5D;;;OAGG;IACI,iBAAiB,gBAA2C;CACpE"}
|
|
@@ -1,144 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
-
exports.CommonConstruct = void 0;
|
|
23
|
-
const constructs_1 = require("constructs");
|
|
24
|
-
const aws = __importStar(require("../manager/aws"));
|
|
25
|
-
const utils = __importStar(require("../utils"));
|
|
26
|
-
/**
|
|
27
|
-
* @stability stable
|
|
28
|
-
* @category Constructs
|
|
29
|
-
* @summary Common construct to use as a base for all higher level constructs.
|
|
30
|
-
*
|
|
31
|
-
* @example
|
|
32
|
-
* import { CommonConstruct } from '@gradientedge/cdk-utils';
|
|
33
|
-
*
|
|
34
|
-
* class CustomConstruct extends CommonConstruct {
|
|
35
|
-
* constructor(parent: cdk.Construct, id: string, props: common.CommonStackProps) {
|
|
36
|
-
* super(parent, id, props);
|
|
37
|
-
* this.props = props;
|
|
38
|
-
* };
|
|
39
|
-
* };
|
|
40
|
-
*
|
|
41
|
-
* @mermaid
|
|
42
|
-
* graph LR;
|
|
43
|
-
* A[CommonConstruct]-.->|extends|B(Construct);
|
|
44
|
-
* B(Construct)-->|implements|C(IConstruct);
|
|
45
|
-
*/
|
|
46
|
-
class CommonConstruct extends constructs_1.Construct {
|
|
47
|
-
props;
|
|
48
|
-
acmManager;
|
|
49
|
-
apiManager;
|
|
50
|
-
appConfigManager;
|
|
51
|
-
codeBuildManager;
|
|
52
|
-
cloudFrontManager;
|
|
53
|
-
cloudTrailManager;
|
|
54
|
-
cloudWatchManager;
|
|
55
|
-
dynamodbManager;
|
|
56
|
-
ecrManager;
|
|
57
|
-
ecsManager;
|
|
58
|
-
eksManager;
|
|
59
|
-
eventManager;
|
|
60
|
-
iamManager;
|
|
61
|
-
lambdaManager;
|
|
62
|
-
logManager;
|
|
63
|
-
route53Manager;
|
|
64
|
-
s3Manager;
|
|
65
|
-
secretsManager;
|
|
66
|
-
snsManager;
|
|
67
|
-
ssMManager;
|
|
68
|
-
vpcManager;
|
|
69
|
-
wafManager;
|
|
70
|
-
fullyQualifiedDomainName;
|
|
71
|
-
/**
|
|
72
|
-
* @summary Constructor to initialise the CommonConstruct
|
|
73
|
-
* @param {Construct} parent
|
|
74
|
-
* @param {string} id scoped id of the resource
|
|
75
|
-
* @param {CommonStackProps} props
|
|
76
|
-
*/
|
|
77
|
-
constructor(parent, id, props) {
|
|
78
|
-
super(parent, id);
|
|
79
|
-
this.props = props;
|
|
80
|
-
this.acmManager = new aws.AcmManager();
|
|
81
|
-
this.apiManager = new aws.ApiManager();
|
|
82
|
-
this.appConfigManager = new aws.AppConfigManager();
|
|
83
|
-
this.codeBuildManager = new aws.CodeBuildManager();
|
|
84
|
-
this.cloudFrontManager = new aws.CloudFrontManager();
|
|
85
|
-
this.cloudTrailManager = new aws.CloudTrailManager();
|
|
86
|
-
this.cloudWatchManager = new aws.CloudWatchManager();
|
|
87
|
-
this.dynamodbManager = new aws.DynamodbManager();
|
|
88
|
-
this.ecrManager = new aws.EcrManager();
|
|
89
|
-
this.ecsManager = new aws.EcsManager();
|
|
90
|
-
this.eksManager = new aws.EksManager();
|
|
91
|
-
this.eventManager = new aws.EventManager();
|
|
92
|
-
this.iamManager = new aws.IamManager();
|
|
93
|
-
this.lambdaManager = new aws.LambdaManager();
|
|
94
|
-
this.logManager = new aws.LogManager();
|
|
95
|
-
this.route53Manager = new aws.Route53Manager();
|
|
96
|
-
this.s3Manager = new aws.S3Manager();
|
|
97
|
-
this.secretsManager = new aws.SecretsManager();
|
|
98
|
-
this.snsManager = new aws.SnsManager();
|
|
99
|
-
this.ssMManager = new aws.SsmManager();
|
|
100
|
-
this.vpcManager = new aws.VpcManager();
|
|
101
|
-
this.wafManager = new aws.WafManager();
|
|
102
|
-
this.determineFullyQualifiedDomain();
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* @summary Helper method to add CloudFormation outputs from the construct
|
|
106
|
-
* @param {string} id scoped id of the resource
|
|
107
|
-
* @param {string} value the value of the exported output
|
|
108
|
-
* @param {string?} description optional description for the output
|
|
109
|
-
* @param {boolean} overrideId Flag which indicates whether to override the default logical id of the output
|
|
110
|
-
*/
|
|
111
|
-
addCfnOutput(id, value, description, overrideId = true) {
|
|
112
|
-
return utils.createCfnOutput(id, this, value, description, overrideId);
|
|
113
|
-
}
|
|
114
|
-
/**
|
|
115
|
-
* @summary Determine the fully qualified domain name based on domainName & subDomain
|
|
116
|
-
*/
|
|
117
|
-
determineFullyQualifiedDomain() {
|
|
118
|
-
this.fullyQualifiedDomainName = this.props.subDomain
|
|
119
|
-
? `${this.props.subDomain}.${this.props.domainName}`
|
|
120
|
-
: this.props.domainName;
|
|
121
|
-
}
|
|
122
|
-
/**
|
|
123
|
-
* @summary Utility method to determine if the initialisation is in development (dev) stage
|
|
124
|
-
* This is determined by the stage property injected via cdk context
|
|
125
|
-
*/
|
|
126
|
-
isDevelopmentStage = () => utils.isDevStage(this.props.stage);
|
|
127
|
-
/**
|
|
128
|
-
* @summary Utility method to determine if the initialisation is in test (tst) stage
|
|
129
|
-
* This is determined by the stage property injected via cdk context
|
|
130
|
-
*/
|
|
131
|
-
isTestStage = () => utils.isTestStage(this.props.stage);
|
|
132
|
-
/**
|
|
133
|
-
* @summary Utility method to determine if the initialisation is in uat (uat) stage
|
|
134
|
-
* This is determined by the stage property injected via cdk context
|
|
135
|
-
*/
|
|
136
|
-
isUatStage = () => utils.isUatStage(this.props.stage);
|
|
137
|
-
/**
|
|
138
|
-
* @summary Utility method to determine if the initialisation is in production (prd) stage
|
|
139
|
-
* This is determined by the stage property injected via cdk context
|
|
140
|
-
*/
|
|
141
|
-
isProductionStage = () => utils.isPrdStage(this.props.stage);
|
|
142
|
-
}
|
|
143
|
-
exports.CommonConstruct = CommonConstruct;
|
|
144
|
-
//# sourceMappingURL=commonConstruct.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commonConstruct.js","sourceRoot":"","sources":["../../../../src/lib/common/commonConstruct.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AACA,2CAAsC;AACtC,oDAAqC;AAErC,gDAAiC;AAEjC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAa,eAAgB,SAAQ,sBAAS;IAC5C,KAAK,CAAwB;IAC7B,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,gBAAgB,CAAsB;IACtC,gBAAgB,CAAsB;IACtC,iBAAiB,CAAuB;IACxC,iBAAiB,CAAuB;IACxC,iBAAiB,CAAuB;IACxC,eAAe,CAAqB;IACpC,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,YAAY,CAAkB;IAC9B,UAAU,CAAgB;IAC1B,aAAa,CAAmB;IAChC,UAAU,CAAgB;IAC1B,cAAc,CAAoB;IAClC,SAAS,CAAe;IACxB,cAAc,CAAoB;IAClC,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,wBAAwB,CAAQ;IAEhC;;;;;OAKG;IACH,YAAY,MAAiB,EAAE,EAAU,EAAE,KAA6B;QACtE,KAAK,CAAC,MAAM,EAAE,EAAE,CAAC,CAAA;QACjB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAA;QAClB,IAAI,CAAC,UAAU,GAAG,IAAI,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0,0 @@
|
|
|
1
|
-
import * as cdk from 'aws-cdk-lib';
|
|
2
|
-
import { CommonStackProps } from '../types';
|
|
3
|
-
import { CommonConstruct } from './commonConstruct';
|
|
4
|
-
/**
|
|
5
|
-
* @stability stable
|
|
6
|
-
* @category Stacks
|
|
7
|
-
* @summary Common stack to use as a base for all higher level constructs.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* import { CommonStack } from '@gradientedge/cdk-utils'
|
|
11
|
-
*
|
|
12
|
-
* class CustomStack extends CommonStack {
|
|
13
|
-
* constructor(parent: cdk.App, name: string, props: cdk.StackProps) {
|
|
14
|
-
* super(parent, name, props)
|
|
15
|
-
* // provision resources
|
|
16
|
-
* }
|
|
17
|
-
* }
|
|
18
|
-
*
|
|
19
|
-
* @mermaid
|
|
20
|
-
* graph LR;
|
|
21
|
-
* A[CommonStack]-.->|extends|B(cdk.Stack);
|
|
22
|
-
* B(cdk.Stack)-->|implements|C(cdk.ITaggable);
|
|
23
|
-
*/
|
|
24
|
-
export declare class CommonStack extends cdk.Stack {
|
|
25
|
-
construct: CommonConstruct;
|
|
26
|
-
props: CommonStackProps;
|
|
27
|
-
/**
|
|
28
|
-
* @summary Constructor to initialise the CommonStack
|
|
29
|
-
* @param {cdk.App} parent
|
|
30
|
-
* @param {string} name
|
|
31
|
-
* @param {cdk.StackProps} props
|
|
32
|
-
*/
|
|
33
|
-
constructor(parent: cdk.App, name: string, props: cdk.StackProps);
|
|
34
|
-
/**
|
|
35
|
-
* @summary Method to determine the core CDK construct properties injected via context cdk.json
|
|
36
|
-
* @param {cdk.StackProps} props The stack properties
|
|
37
|
-
* @return The stack properties
|
|
38
|
-
*/
|
|
39
|
-
protected determineConstructProps(props: cdk.StackProps): {
|
|
40
|
-
stackName: string | undefined;
|
|
41
|
-
name: string;
|
|
42
|
-
region: any;
|
|
43
|
-
stage: any;
|
|
44
|
-
domainName: any;
|
|
45
|
-
subDomain: any;
|
|
46
|
-
extraContexts: any;
|
|
47
|
-
};
|
|
48
|
-
/**
|
|
49
|
-
* @summary Method to determine extra cdk contexts apart from the main cdk.json
|
|
50
|
-
* - Sets the properties from the extra contexts into cdk node context
|
|
51
|
-
* - Primary use is to have layered config in separate files to enable easier maintenance and readability
|
|
52
|
-
*/
|
|
53
|
-
protected determineExtraContexts(): void;
|
|
54
|
-
/**
|
|
55
|
-
* @summary Method to determine extra cdk stage contexts apart from the main cdk.json
|
|
56
|
-
* - Sets the properties from the extra stage contexts into cdk node context
|
|
57
|
-
* - Primary use is to have layered config for each environment which is injected into the context
|
|
58
|
-
*/
|
|
59
|
-
protected determineStageContexts(): void;
|
|
60
|
-
/**
|
|
61
|
-
* @summary Determine the fully qualified domain name based on domainName & subDomain
|
|
62
|
-
*/
|
|
63
|
-
protected fullyQualifiedDomain(): any;
|
|
64
|
-
}
|
|
65
|
-
//# sourceMappingURL=commonStack.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commonStack.d.ts","sourceRoot":"","sources":["../../../../src/lib/common/commonStack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,GAAG,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAA;AAE3C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAKnD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,qBAAa,WAAY,SAAQ,GAAG,CAAC,KAAK;IACxC,SAAS,EAAE,eAAe,CAAA;IAC1B,KAAK,EAAE,gBAAgB,CAAA;IACvB;;;;;OAKG;gBACS,MAAM,EAAE,GAAG,CAAC,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,CAAC,UAAU;IAehE;;;;OAIG;IACH,SAAS,CAAC,uBAAuB,CAAC,KAAK,EAAE,GAAG,CAAC,UAAU;;;;;;;;;IAYvD;;;;OAIG;IACH,SAAS,CAAC,sBAAsB;IA4BhC;;;;OAIG;IACH,SAAS,CAAC,sBAAsB;IAsChC;;OAEG;IACH,SAAS,CAAC,oBAAoB;CAK/B"}
|
|
@@ -1,158 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
-
exports.CommonStack = void 0;
|
|
23
|
-
const cdk = __importStar(require("aws-cdk-lib"));
|
|
24
|
-
const utils_1 = require("../utils");
|
|
25
|
-
const commonConstruct_1 = require("./commonConstruct");
|
|
26
|
-
const appRoot = require('app-root-path');
|
|
27
|
-
const fs = require('fs');
|
|
28
|
-
/**
|
|
29
|
-
* @stability stable
|
|
30
|
-
* @category Stacks
|
|
31
|
-
* @summary Common stack to use as a base for all higher level constructs.
|
|
32
|
-
*
|
|
33
|
-
* @example
|
|
34
|
-
* import { CommonStack } from '@gradientedge/cdk-utils'
|
|
35
|
-
*
|
|
36
|
-
* class CustomStack extends CommonStack {
|
|
37
|
-
* constructor(parent: cdk.App, name: string, props: cdk.StackProps) {
|
|
38
|
-
* super(parent, name, props)
|
|
39
|
-
* // provision resources
|
|
40
|
-
* }
|
|
41
|
-
* }
|
|
42
|
-
*
|
|
43
|
-
* @mermaid
|
|
44
|
-
* graph LR;
|
|
45
|
-
* A[CommonStack]-.->|extends|B(cdk.Stack);
|
|
46
|
-
* B(cdk.Stack)-->|implements|C(cdk.ITaggable);
|
|
47
|
-
*/
|
|
48
|
-
class CommonStack extends cdk.Stack {
|
|
49
|
-
construct;
|
|
50
|
-
props;
|
|
51
|
-
/**
|
|
52
|
-
* @summary Constructor to initialise the CommonStack
|
|
53
|
-
* @param {cdk.App} parent
|
|
54
|
-
* @param {string} name
|
|
55
|
-
* @param {cdk.StackProps} props
|
|
56
|
-
*/
|
|
57
|
-
constructor(parent, name, props) {
|
|
58
|
-
super(parent, name, props);
|
|
59
|
-
/* determine extra cdk contexts */
|
|
60
|
-
this.determineExtraContexts();
|
|
61
|
-
/* determine extra cdk stage contexts */
|
|
62
|
-
this.determineStageContexts();
|
|
63
|
-
this.props = this.determineConstructProps(props);
|
|
64
|
-
/* initialise the construct */
|
|
65
|
-
this.construct = new commonConstruct_1.CommonConstruct(this, 'cdk-utils', this.props);
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* @summary Method to determine the core CDK construct properties injected via context cdk.json
|
|
69
|
-
* @param {cdk.StackProps} props The stack properties
|
|
70
|
-
* @return The stack properties
|
|
71
|
-
*/
|
|
72
|
-
determineConstructProps(props) {
|
|
73
|
-
return {
|
|
74
|
-
stackName: props.stackName,
|
|
75
|
-
name: props.stackName || 'cdk-utils',
|
|
76
|
-
region: this.node.tryGetContext('region'),
|
|
77
|
-
stage: this.node.tryGetContext('stage'),
|
|
78
|
-
domainName: this.node.tryGetContext('domainName'),
|
|
79
|
-
subDomain: this.node.tryGetContext('subDomain'),
|
|
80
|
-
extraContexts: this.node.tryGetContext('extraContexts'),
|
|
81
|
-
};
|
|
82
|
-
}
|
|
83
|
-
/**
|
|
84
|
-
* @summary Method to determine extra cdk contexts apart from the main cdk.json
|
|
85
|
-
* - Sets the properties from the extra contexts into cdk node context
|
|
86
|
-
* - Primary use is to have layered config in separate files to enable easier maintenance and readability
|
|
87
|
-
*/
|
|
88
|
-
determineExtraContexts() {
|
|
89
|
-
const extraContexts = this.node.tryGetContext('extraContexts');
|
|
90
|
-
if (!extraContexts) {
|
|
91
|
-
console.info(`No additional contexts provided. Using default context properties from cdk.json`);
|
|
92
|
-
return;
|
|
93
|
-
}
|
|
94
|
-
extraContexts.forEach((context) => {
|
|
95
|
-
const extraContextPath = `${appRoot.path}/${context}`;
|
|
96
|
-
/* scenario where extra context is configured in cdk.json but absent in file system */
|
|
97
|
-
if (!fs.existsSync(extraContextPath))
|
|
98
|
-
throw `Extra context properties unavailable in path:${extraContextPath}`;
|
|
99
|
-
/* read the extra properties */
|
|
100
|
-
const extraContextPropsBuffer = fs.readFileSync(extraContextPath);
|
|
101
|
-
console.info(`Adding additional contexts provided in ${extraContextPath}`);
|
|
102
|
-
/* parse as JSON properties */
|
|
103
|
-
const extraContextProps = JSON.parse(extraContextPropsBuffer);
|
|
104
|
-
/* set each of the property into the cdk node context */
|
|
105
|
-
Object.keys(extraContextProps).forEach((propKey) => {
|
|
106
|
-
this.node.setContext(propKey, extraContextProps[propKey]);
|
|
107
|
-
});
|
|
108
|
-
});
|
|
109
|
-
}
|
|
110
|
-
/**
|
|
111
|
-
* @summary Method to determine extra cdk stage contexts apart from the main cdk.json
|
|
112
|
-
* - Sets the properties from the extra stage contexts into cdk node context
|
|
113
|
-
* - Primary use is to have layered config for each environment which is injected into the context
|
|
114
|
-
*/
|
|
115
|
-
determineStageContexts() {
|
|
116
|
-
const stage = this.node.tryGetContext('stage');
|
|
117
|
-
const stageContextPath = this.node.tryGetContext('stageContextPath') || 'cdkEnv';
|
|
118
|
-
const stageContextFilePath = `${appRoot.path}/${stageContextPath}/${stage}.json`;
|
|
119
|
-
if ((0, utils_1.isDevStage)(stage)) {
|
|
120
|
-
console.info(`Development stage. Using default stage context properties`);
|
|
121
|
-
}
|
|
122
|
-
/* alert default context usage when extra stage config is missing */
|
|
123
|
-
if (!fs.existsSync(stageContextFilePath)) {
|
|
124
|
-
console.info(`Stage specific context properties unavailable in path:${stageContextFilePath}`);
|
|
125
|
-
console.info(`Using default stage context properties for ${stage} stage`);
|
|
126
|
-
return;
|
|
127
|
-
}
|
|
128
|
-
/* read the extra properties */
|
|
129
|
-
const stageContextPropsBuffer = fs.readFileSync(stageContextFilePath);
|
|
130
|
-
console.info(`Adding additional stage contexts provided in ${stageContextFilePath}`);
|
|
131
|
-
/* parse as JSON properties */
|
|
132
|
-
const stageContextProps = JSON.parse(stageContextPropsBuffer);
|
|
133
|
-
/* set each of the property into the cdk node context */
|
|
134
|
-
Object.keys(stageContextProps).forEach((propKey) => {
|
|
135
|
-
/* handle object, array properties */
|
|
136
|
-
if (typeof stageContextProps[propKey] === 'object' && !Array.isArray(stageContextProps[propKey])) {
|
|
137
|
-
this.node.setContext(propKey, {
|
|
138
|
-
...this.node.tryGetContext(propKey),
|
|
139
|
-
...stageContextProps[propKey],
|
|
140
|
-
});
|
|
141
|
-
}
|
|
142
|
-
else {
|
|
143
|
-
/* handle all other primitive properties */
|
|
144
|
-
this.node.setContext(propKey, stageContextProps[propKey]);
|
|
145
|
-
}
|
|
146
|
-
});
|
|
147
|
-
}
|
|
148
|
-
/**
|
|
149
|
-
* @summary Determine the fully qualified domain name based on domainName & subDomain
|
|
150
|
-
*/
|
|
151
|
-
fullyQualifiedDomain() {
|
|
152
|
-
const domainName = this.node.tryGetContext('domainName');
|
|
153
|
-
const subDomain = this.node.tryGetContext('subDomain');
|
|
154
|
-
return subDomain ? `${subDomain}.${domainName}` : domainName;
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
exports.CommonStack = CommonStack;
|
|
158
|
-
//# sourceMappingURL=commonStack.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":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;;OAEG;IACO,oBAAoB;QAC5B,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,YAAY,CAAC,CAAA;QACxD,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,WAAW,CAAC,CAAA;QACtD,OAAO,SAAS,CAAC,CAAC,CAAC,GAAG,SAAS,IAAI,UAAU,EAAE,CAAC,CAAC,CAAC,UAAU,CAAA;IAC9D,CAAC;CACF;AA7HD,kCA6HC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/common/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAA;AACjC,cAAc,eAAe,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./commonConstruct"), exports);
|
|
14
|
-
__exportStar(require("./commonStack"), exports);
|
|
15
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/common/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiC;AACjC,gDAA6B"}
|
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
import * as apig from 'aws-cdk-lib/aws-apigateway';
|
|
2
|
-
import * as acm from 'aws-cdk-lib/aws-certificatemanager';
|
|
3
|
-
import * as iam from 'aws-cdk-lib/aws-iam';
|
|
4
|
-
import * as lambda from 'aws-cdk-lib/aws-lambda';
|
|
5
|
-
import * as route53 from 'aws-cdk-lib/aws-route53';
|
|
6
|
-
import * as secretsmanager from 'aws-cdk-lib/aws-secretsmanager';
|
|
7
|
-
import { Construct } from 'constructs';
|
|
8
|
-
import { CommonConstruct } from '../common';
|
|
9
|
-
import { GraphQlApiLambdaEnvironment, GraphQlApiLambdaProps } from '../types';
|
|
10
|
-
/**
|
|
11
|
-
* @stability stable
|
|
12
|
-
* @category Constructs
|
|
13
|
-
* @summary Provides a construct to create and deploy a Graphql API as Lambda
|
|
14
|
-
*
|
|
15
|
-
* @example
|
|
16
|
-
* import { GraphQLApiLambda, GraphQlApiLambdaProps } '@gradientedge/cdk-utils'
|
|
17
|
-
* import { Construct } from 'constructs'
|
|
18
|
-
*
|
|
19
|
-
* class CustomConstruct extends GraphQLApiLambda {
|
|
20
|
-
* constructor(parent: Construct, id: string, props: GraphQlApiLambdaProps) {
|
|
21
|
-
* super(parent, id, props)
|
|
22
|
-
* this.props = props
|
|
23
|
-
* this.id = id
|
|
24
|
-
* this.initResources()
|
|
25
|
-
* }
|
|
26
|
-
* }
|
|
27
|
-
*
|
|
28
|
-
* @mermaid
|
|
29
|
-
* graph LR;
|
|
30
|
-
* A[GraphQLApiLambda]-.->|extends|B(CommonConstruct);
|
|
31
|
-
* B(CommonConstruct)-->|extends|C(Construct);
|
|
32
|
-
* C(Construct)-->|implements|D(IConstruct);
|
|
33
|
-
*/
|
|
34
|
-
export declare class GraphQLApiLambda extends CommonConstruct {
|
|
35
|
-
props: GraphQlApiLambdaProps;
|
|
36
|
-
id: string;
|
|
37
|
-
applicationSecrets: secretsmanager.ISecret[];
|
|
38
|
-
graphQLApiLambdaPolicy: iam.PolicyDocument;
|
|
39
|
-
graphQLApiLambdaRole: iam.Role;
|
|
40
|
-
graphQLApiLambdaEnvironment: GraphQlApiLambdaEnvironment;
|
|
41
|
-
graphQLApiLambdaLayers: lambda.LayerVersion[];
|
|
42
|
-
graphQLApiLambdaFunction: lambda.Function;
|
|
43
|
-
graphQLApi: apig.RestApi;
|
|
44
|
-
graphQLApiHostedZone: route53.IHostedZone;
|
|
45
|
-
graphQLApiCertificate: acm.ICertificate;
|
|
46
|
-
graphQLApiDomain: apig.DomainName;
|
|
47
|
-
graphQLApiBasePathMappings: apig.BasePathMapping[];
|
|
48
|
-
/**
|
|
49
|
-
* @summary Constructor to initialise the GraphQLApiLambda Construct
|
|
50
|
-
* @param {Construct} parent
|
|
51
|
-
* @param {string} id
|
|
52
|
-
* @param {GraphQlApiLambdaProps} props
|
|
53
|
-
*/
|
|
54
|
-
constructor(parent: Construct, id: string, props: GraphQlApiLambdaProps);
|
|
55
|
-
/**
|
|
56
|
-
* @summary Initialise and provision resources
|
|
57
|
-
* @protected
|
|
58
|
-
*/
|
|
59
|
-
protected initResources(): void;
|
|
60
|
-
/**
|
|
61
|
-
* @summary Method to resolve secrets from SecretsManager
|
|
62
|
-
* - To be implemented in the overriding method in the implementation class
|
|
63
|
-
* @protected
|
|
64
|
-
*/
|
|
65
|
-
protected resolveSecrets(): void;
|
|
66
|
-
/**
|
|
67
|
-
* @summary Method to resolve a hosted zone based on domain attributes
|
|
68
|
-
* @protected
|
|
69
|
-
*/
|
|
70
|
-
protected resolveHostedZone(): void;
|
|
71
|
-
/**
|
|
72
|
-
* @summary Method to resolve a certificate based on attributes
|
|
73
|
-
* @protected
|
|
74
|
-
*/
|
|
75
|
-
protected resolveCertificate(): void;
|
|
76
|
-
/**
|
|
77
|
-
* @summary Method to create iam policy for GraphQL Lambda function
|
|
78
|
-
* @protected
|
|
79
|
-
*/
|
|
80
|
-
protected createLambdaPolicy(): void;
|
|
81
|
-
/**
|
|
82
|
-
* @summary Method to create iam role for GraphQL Lambda function
|
|
83
|
-
* @protected
|
|
84
|
-
*/
|
|
85
|
-
protected createLambdaRole(): void;
|
|
86
|
-
/**
|
|
87
|
-
* @summary Method to create environment variables for GraphQL Lambda function
|
|
88
|
-
* @protected
|
|
89
|
-
*/
|
|
90
|
-
protected createLambdaEnvironment(): void;
|
|
91
|
-
/**
|
|
92
|
-
* @summary Method to create layers for GraphQL Lambda function
|
|
93
|
-
* @protected
|
|
94
|
-
*/
|
|
95
|
-
protected createLambdaLayers(): void;
|
|
96
|
-
/**
|
|
97
|
-
* @summary Method to create lambda function for GraphQL
|
|
98
|
-
* @protected
|
|
99
|
-
*/
|
|
100
|
-
protected createLambdaFunction(): void;
|
|
101
|
-
/**
|
|
102
|
-
* @summary Method to create rest api for GraphQL
|
|
103
|
-
* @protected
|
|
104
|
-
*/
|
|
105
|
-
protected createRestApi(): void;
|
|
106
|
-
/**
|
|
107
|
-
* @summary Method to create custom api domain for GraphQL API
|
|
108
|
-
* @protected
|
|
109
|
-
*/
|
|
110
|
-
protected createApiDomain(): void;
|
|
111
|
-
/**
|
|
112
|
-
* @summary Method to create base path mappings for GraphQL API
|
|
113
|
-
* @protected
|
|
114
|
-
*/
|
|
115
|
-
protected createApiBasePathMapping(): void;
|
|
116
|
-
/**
|
|
117
|
-
* @summary Method to create route53 records for GraphQL API
|
|
118
|
-
* @protected
|
|
119
|
-
*/
|
|
120
|
-
protected createApiRouteAssets(): void;
|
|
121
|
-
}
|
|
122
|
-
//# sourceMappingURL=graphQLApiLambda.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphQLApiLambda.d.ts","sourceRoot":"","sources":["../../../../src/lib/construct/graphQLApiLambda.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,4BAA4B,CAAA;AAClD,OAAO,KAAK,GAAG,MAAM,oCAAoC,CAAA;AACzD,OAAO,KAAK,GAAG,MAAM,qBAAqB,CAAA;AAC1C,OAAO,KAAK,MAAM,MAAM,wBAAwB,CAAA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