From e9d00289fde4efce03eafe848ab3b040b53cc859 Mon Sep 17 00:00:00 2001 From: Andrei Palchys Date: Mon, 27 Nov 2023 11:12:12 +0200 Subject: [PATCH] fix: cdk --- package-lock.json | 42 +++++++++++++++++++++++++++++++++++ package.json | 1 + src/cdk/AngularCourseStack.ts | 2 +- 3 files changed, 44 insertions(+), 1 deletion(-) diff --git a/package-lock.json b/package-lock.json index f061f2f..31dff7c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,6 +8,7 @@ "@aws-cdk/aws-apigatewayv2-alpha": "2.110.0-alpha.0", "@aws-cdk/aws-apigatewayv2-integrations-alpha": "2.110.0-alpha.0", "@aws-sdk/client-dynamodb": "^3.458.0", + "aws-cdk": "2.110.1", "aws-cdk-lib": "2.110.1", "constructs": "^10", "querystring": "^0.2.1", @@ -1623,6 +1624,20 @@ "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" }, + "node_modules/aws-cdk": { + "version": "2.110.1", + "resolved": "https://registry.npmjs.org/aws-cdk/-/aws-cdk-2.110.1.tgz", + "integrity": "sha512-/V0FOgsvD/FkFANrYnSmyb+XK56tm2oE86pUCoEggQ2tka6Zm0z9blKZQV4euMErNSkWz4ReSAKenaqk86Fr5Q==", + "bin": { + "cdk": "bin/cdk" + }, + "engines": { + "node": ">= 14.15.0" + }, + "optionalDependencies": { + "fsevents": "2.3.2" + } + }, "node_modules/aws-cdk-lib": { "version": "2.110.1", "resolved": "https://registry.npmjs.org/aws-cdk-lib/-/aws-cdk-lib-2.110.1.tgz", @@ -2047,6 +2062,19 @@ "fxparser": "src/cli/cli.js" } }, + "node_modules/fsevents": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", + "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, "node_modules/make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", @@ -3388,6 +3416,14 @@ "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" }, + "aws-cdk": { + "version": "2.110.1", + "resolved": "https://registry.npmjs.org/aws-cdk/-/aws-cdk-2.110.1.tgz", + "integrity": "sha512-/V0FOgsvD/FkFANrYnSmyb+XK56tm2oE86pUCoEggQ2tka6Zm0z9blKZQV4euMErNSkWz4ReSAKenaqk86Fr5Q==", + "requires": { + "fsevents": "2.3.2" + } + }, "aws-cdk-lib": { "version": "2.110.1", "resolved": "https://registry.npmjs.org/aws-cdk-lib/-/aws-cdk-lib-2.110.1.tgz", @@ -3661,6 +3697,12 @@ "strnum": "^1.0.5" } }, + "fsevents": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", + "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "optional": true + }, "make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", diff --git a/package.json b/package.json index 9e98a49..a27e35a 100644 --- a/package.json +++ b/package.json @@ -8,6 +8,7 @@ "@aws-cdk/aws-apigatewayv2-alpha": "2.110.0-alpha.0", "@aws-cdk/aws-apigatewayv2-integrations-alpha": "2.110.0-alpha.0", "@aws-sdk/client-dynamodb": "^3.458.0", + "aws-cdk": "2.110.1", "aws-cdk-lib": "2.110.1", "constructs": "^10", "querystring": "^0.2.1", diff --git a/src/cdk/AngularCourseStack.ts b/src/cdk/AngularCourseStack.ts index 1450666..f81561c 100644 --- a/src/cdk/AngularCourseStack.ts +++ b/src/cdk/AngularCourseStack.ts @@ -154,7 +154,7 @@ export class AngularCourseStack extends cdk.Stack { originConfigs: [ { customOriginSource: { - domainName: httpApi.url!, + domainName: `${httpApi.httpApiId}.execute-api.${this.region}.amazonaws.com`, originProtocolPolicy: cloudfront.OriginProtocolPolicy.HTTPS_ONLY, }, behaviors: [