From 39738d760b07a793908e3846d361c16e1b444bf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Barthelet?= Date: Wed, 27 Apr 2022 16:20:47 +0200 Subject: [PATCH 1/5] Upgrade to CDK v2 --- package.json | 19 +++---------------- src/CloudFormation.ts | 4 ++-- src/constructs/abstracts/AwsConstruct.ts | 2 +- .../aws/DatabaseDynamoDBSingleTable.ts | 6 +++--- src/constructs/aws/Queue.ts | 16 ++++++++-------- src/constructs/aws/ServerSideWebsite.ts | 16 ++++++++-------- src/constructs/aws/SinglePageApp.ts | 6 +++--- src/constructs/aws/StaticWebsite.ts | 6 +++--- src/constructs/aws/Storage.ts | 6 +++--- src/constructs/aws/Vpc.ts | 6 +++--- src/constructs/aws/Webhook.ts | 13 +++++++------ .../aws/abstracts/StaticWebsiteAbstract.ts | 18 +++++++++--------- src/plugin.ts | 2 +- src/providers/AwsProvider.ts | 4 ++-- src/types/serverless.ts | 2 +- .../getDefaultCfnFunctionAssociations.ts | 2 +- test/utils/runServerless.ts | 2 +- 17 files changed, 59 insertions(+), 71 deletions(-) diff --git a/package.json b/package.json index b92f0a7f..cb291199 100644 --- a/package.json +++ b/package.json @@ -5,26 +5,13 @@ "repository": "https://github.com/getlift/lift", "description": "Lift", "dependencies": { - "@aws-cdk/aws-apigatewayv2": "^1.138", - "@aws-cdk/aws-apigatewayv2-integrations": "^1.138", - "@aws-cdk/aws-certificatemanager": "^1.138", - "@aws-cdk/aws-cloudfront": "^1.138", - "@aws-cdk/aws-cloudfront-origins": "^1.138", - "@aws-cdk/aws-cloudwatch": "^1.138", - "@aws-cdk/aws-dynamodb": "^1.138", - "@aws-cdk/aws-ec2": "^1.138", - "@aws-cdk/aws-events": "^1.138", - "@aws-cdk/aws-iam": "^1.138", - "@aws-cdk/aws-kms": "^1.138", - "@aws-cdk/aws-lambda": "^1.138", - "@aws-cdk/aws-s3": "^1.138", - "@aws-cdk/aws-sns": "^1.138", - "@aws-cdk/aws-sqs": "^1.138", - "@aws-cdk/core": "^1.138", + "@aws-cdk/aws-apigatewayv2-alpha": "^2.21.1-alpha.0", + "aws-cdk-lib": "^2.21.1", "aws-sdk": "^2.942.0", "chalk": "^4.1.1", "change-case": "^4.1.2", "cidr-split": "^0.1.2", + "constructs": "^10.0.127", "inquirer": "^7.3.3", "js-yaml": "^3.14.1", "lodash": "^4.17.21", diff --git a/src/CloudFormation.ts b/src/CloudFormation.ts index f9673f4a..b2bf0000 100644 --- a/src/CloudFormation.ts +++ b/src/CloudFormation.ts @@ -1,6 +1,6 @@ import type { DescribeStacksInput, DescribeStacksOutput } from "aws-sdk/clients/cloudformation"; -import type { CfnOutput } from "@aws-cdk/core"; -import { Stack } from "@aws-cdk/core"; +import type { CfnOutput } from "aws-cdk-lib"; +import { Stack } from "aws-cdk-lib"; import type { AwsProvider } from "@lift/providers"; import { getUtils } from "./utils/logger"; diff --git a/src/constructs/abstracts/AwsConstruct.ts b/src/constructs/abstracts/AwsConstruct.ts index e68cb760..f155d2c3 100644 --- a/src/constructs/abstracts/AwsConstruct.ts +++ b/src/constructs/abstracts/AwsConstruct.ts @@ -1,4 +1,4 @@ -import { Construct as CdkConstruct } from "@aws-cdk/core"; +import { Construct as CdkConstruct } from "constructs"; import type { AwsProvider } from "@lift/providers"; import type { ConstructInterface } from "@lift/constructs"; diff --git a/src/constructs/aws/DatabaseDynamoDBSingleTable.ts b/src/constructs/aws/DatabaseDynamoDBSingleTable.ts index 7178f7aa..91e8b00e 100644 --- a/src/constructs/aws/DatabaseDynamoDBSingleTable.ts +++ b/src/constructs/aws/DatabaseDynamoDBSingleTable.ts @@ -1,6 +1,6 @@ -import type { Construct as CdkConstruct } from "@aws-cdk/core"; -import { CfnOutput, Fn, Stack } from "@aws-cdk/core"; -import { AttributeType, BillingMode, StreamViewType, Table } from "@aws-cdk/aws-dynamodb"; +import type { Construct as CdkConstruct } from "constructs"; +import { CfnOutput, Fn, Stack } from "aws-cdk-lib"; +import { AttributeType, BillingMode, StreamViewType, Table } from "aws-cdk-lib/aws-dynamodb"; import type { FromSchema } from "json-schema-to-ts"; import type { AwsProvider } from "@lift/providers"; import { AwsConstruct } from "@lift/constructs/abstracts"; diff --git a/src/constructs/aws/Queue.ts b/src/constructs/aws/Queue.ts index 7fbd2f61..a97347f1 100644 --- a/src/constructs/aws/Queue.ts +++ b/src/constructs/aws/Queue.ts @@ -1,11 +1,11 @@ -import { Key } from "@aws-cdk/aws-kms"; -import { Queue as CdkQueue, QueueEncryption } from "@aws-cdk/aws-sqs"; +import { Key } from "aws-cdk-lib/aws-kms"; +import { Queue as CdkQueue, QueueEncryption } from "aws-cdk-lib/aws-sqs"; import type { FromSchema } from "json-schema-to-ts"; -import { Alarm, ComparisonOperator, Metric } from "@aws-cdk/aws-cloudwatch"; -import { Subscription, SubscriptionProtocol, Topic } from "@aws-cdk/aws-sns"; -import type { AlarmActionConfig } from "@aws-cdk/aws-cloudwatch/lib/alarm-action"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; -import { CfnOutput, Duration } from "@aws-cdk/core"; +import { Alarm, ComparisonOperator, Metric } from "aws-cdk-lib/aws-cloudwatch"; +import { Subscription, SubscriptionProtocol, Topic } from "aws-cdk-lib/aws-sns"; +import type { AlarmActionConfig } from "aws-cdk-lib/aws-cloudwatch/lib/alarm-action"; +import type { Construct as CdkConstruct } from "constructs"; +import { CfnOutput, Duration } from "aws-cdk-lib"; import chalk from "chalk"; import type { PurgeQueueRequest, SendMessageRequest } from "aws-sdk/clients/sqs"; import { isNil } from "lodash"; @@ -221,7 +221,7 @@ export class Queue extends AwsConstruct { metric: new Metric({ namespace: "AWS/SQS", metricName: "ApproximateNumberOfMessagesVisible", - dimensions: { + dimensionsMap: { QueueName: dlq.queueName, }, statistic: "Sum", diff --git a/src/constructs/aws/ServerSideWebsite.ts b/src/constructs/aws/ServerSideWebsite.ts index 4413441b..c97eb047 100644 --- a/src/constructs/aws/ServerSideWebsite.ts +++ b/src/constructs/aws/ServerSideWebsite.ts @@ -1,4 +1,4 @@ -import { Bucket } from "@aws-cdk/aws-s3"; +import { Bucket } from "aws-cdk-lib/aws-s3"; import { AllowedMethods, CacheHeaderBehavior, @@ -12,17 +12,17 @@ import { OriginRequestPolicy, OriginRequestQueryStringBehavior, ViewerProtocolPolicy, -} from "@aws-cdk/aws-cloudfront"; -import type { Construct } from "@aws-cdk/core"; -import { CfnOutput, Duration, Fn, RemovalPolicy } from "@aws-cdk/core"; +} from "aws-cdk-lib/aws-cloudfront"; +import type { Construct } from "constructs"; +import { CfnOutput, Duration, Fn, RemovalPolicy } from "aws-cdk-lib"; import type { FromSchema } from "json-schema-to-ts"; -import { HttpOrigin, S3Origin } from "@aws-cdk/aws-cloudfront-origins"; -import * as acm from "@aws-cdk/aws-certificatemanager"; -import type { BehaviorOptions, ErrorResponse } from "@aws-cdk/aws-cloudfront/lib/distribution"; +import { HttpOrigin, S3Origin } from "aws-cdk-lib/aws-cloudfront-origins"; +import * as acm from "aws-cdk-lib/aws-certificatemanager"; +import type { BehaviorOptions, ErrorResponse } from "aws-cdk-lib/aws-cloudfront/lib/distribution"; import * as path from "path"; import * as fs from "fs"; import { flatten } from "lodash"; -import * as cloudfront from "@aws-cdk/aws-cloudfront"; +import * as cloudfront from "aws-cdk-lib/aws-cloudfront"; import { AwsConstruct } from "@lift/constructs/abstracts"; import type { ConstructCommands } from "@lift/constructs"; import type { AwsProvider } from "@lift/providers"; diff --git a/src/constructs/aws/SinglePageApp.ts b/src/constructs/aws/SinglePageApp.ts index afc21c65..4c6404ba 100644 --- a/src/constructs/aws/SinglePageApp.ts +++ b/src/constructs/aws/SinglePageApp.ts @@ -1,6 +1,6 @@ -import * as cloudfront from "@aws-cdk/aws-cloudfront"; -import { FunctionEventType } from "@aws-cdk/aws-cloudfront"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; +import * as cloudfront from "aws-cdk-lib/aws-cloudfront"; +import { FunctionEventType } from "aws-cdk-lib/aws-cloudfront"; +import type { Construct as CdkConstruct } from "constructs"; import type { AwsProvider } from "@lift/providers"; import { redirectToMainDomain } from "../../classes/cloudfrontFunctions"; import { getCfnFunctionAssociations } from "../../utils/getDefaultCfnFunctionAssociations"; diff --git a/src/constructs/aws/StaticWebsite.ts b/src/constructs/aws/StaticWebsite.ts index b6af9cc6..b98dc144 100644 --- a/src/constructs/aws/StaticWebsite.ts +++ b/src/constructs/aws/StaticWebsite.ts @@ -1,6 +1,6 @@ -import * as cloudfront from "@aws-cdk/aws-cloudfront"; -import { FunctionEventType } from "@aws-cdk/aws-cloudfront"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; +import * as cloudfront from "aws-cdk-lib/aws-cloudfront"; +import { FunctionEventType } from "aws-cdk-lib/aws-cloudfront"; +import type { Construct as CdkConstruct } from "constructs"; import type { AwsProvider } from "@lift/providers"; import { redirectToMainDomain } from "../../classes/cloudfrontFunctions"; import { getCfnFunctionAssociations } from "../../utils/getDefaultCfnFunctionAssociations"; diff --git a/src/constructs/aws/Storage.ts b/src/constructs/aws/Storage.ts index 276c2ed5..8f506443 100644 --- a/src/constructs/aws/Storage.ts +++ b/src/constructs/aws/Storage.ts @@ -1,6 +1,6 @@ -import { BlockPublicAccess, Bucket, BucketEncryption, StorageClass } from "@aws-cdk/aws-s3"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; -import { CfnOutput, Duration, Fn, Stack } from "@aws-cdk/core"; +import { BlockPublicAccess, Bucket, BucketEncryption, StorageClass } from "aws-cdk-lib/aws-s3"; +import type { Construct as CdkConstruct } from "constructs"; +import { CfnOutput, Duration, Fn, Stack } from "aws-cdk-lib"; import type { FromSchema } from "json-schema-to-ts"; import type { AwsProvider } from "@lift/providers"; import { AwsConstruct } from "@lift/constructs/abstracts"; diff --git a/src/constructs/aws/Vpc.ts b/src/constructs/aws/Vpc.ts index c4f00d76..502165e4 100644 --- a/src/constructs/aws/Vpc.ts +++ b/src/constructs/aws/Vpc.ts @@ -1,5 +1,5 @@ -import { Vpc as CdkVpc, Peer, Port, SecurityGroup } from "@aws-cdk/aws-ec2"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; +import { Vpc as CdkVpc, Peer, Port, SecurityGroup } from "aws-cdk-lib/aws-ec2"; +import type { Construct as CdkConstruct } from "constructs"; import type { FromSchema } from "json-schema-to-ts"; import type { AwsProvider } from "@lift/providers"; import type { ConstructInterface } from "@lift/constructs"; @@ -39,7 +39,7 @@ export class Vpc extends CdkVpc implements ConstructInterface { // Auto-register the VPC provider.setVpcConfig( - [this.appSecurityGroup.securityGroupName], + [this.appSecurityGroup.securityGroupId], this.privateSubnets.map((subnet) => subnet.subnetId) ); } diff --git a/src/constructs/aws/Webhook.ts b/src/constructs/aws/Webhook.ts index 08d44e1c..aec77f7b 100644 --- a/src/constructs/aws/Webhook.ts +++ b/src/constructs/aws/Webhook.ts @@ -1,10 +1,11 @@ -import type { Construct as CdkConstruct } from "@aws-cdk/core"; -import { CfnOutput, Fn } from "@aws-cdk/core"; -import { CfnAuthorizer, CfnIntegration, CfnRoute, HttpApi } from "@aws-cdk/aws-apigatewayv2"; -import { Function } from "@aws-cdk/aws-lambda"; -import { EventBus } from "@aws-cdk/aws-events"; +import type { Construct as CdkConstruct } from "constructs"; +import { CfnOutput, Fn } from "aws-cdk-lib"; +import { CfnAuthorizer, CfnIntegration, CfnRoute } from "aws-cdk-lib/aws-apigatewayv2"; +import { HttpApi } from "@aws-cdk/aws-apigatewayv2-alpha"; +import { Function } from "aws-cdk-lib/aws-lambda"; +import { EventBus } from "aws-cdk-lib/aws-events"; import type { FromSchema } from "json-schema-to-ts"; -import { PolicyDocument, PolicyStatement, Role, ServicePrincipal } from "@aws-cdk/aws-iam"; +import { PolicyDocument, PolicyStatement, Role, ServicePrincipal } from "aws-cdk-lib/aws-iam"; import type { AwsProvider } from "@lift/providers"; import { AwsConstruct } from "@lift/constructs/abstracts"; import ServerlessError from "../../utils/error"; diff --git a/src/constructs/aws/abstracts/StaticWebsiteAbstract.ts b/src/constructs/aws/abstracts/StaticWebsiteAbstract.ts index 24f1f52d..5b1aa4a1 100644 --- a/src/constructs/aws/abstracts/StaticWebsiteAbstract.ts +++ b/src/constructs/aws/abstracts/StaticWebsiteAbstract.ts @@ -1,6 +1,6 @@ -import * as acm from "@aws-cdk/aws-certificatemanager"; -import * as cloudfront from "@aws-cdk/aws-cloudfront"; -import type { ErrorResponse } from "@aws-cdk/aws-cloudfront"; +import * as acm from "aws-cdk-lib/aws-certificatemanager"; +import * as cloudfront from "aws-cdk-lib/aws-cloudfront"; +import type { ErrorResponse } from "aws-cdk-lib/aws-cloudfront"; import { AllowedMethods, CachePolicy, @@ -8,12 +8,12 @@ import { FunctionEventType, HttpVersion, ViewerProtocolPolicy, -} from "@aws-cdk/aws-cloudfront"; -import { S3Origin } from "@aws-cdk/aws-cloudfront-origins"; -import { Bucket } from "@aws-cdk/aws-s3"; -import type { Construct as CdkConstruct } from "@aws-cdk/core"; -import { Duration } from "@aws-cdk/core"; -import { CfnOutput, RemovalPolicy } from "@aws-cdk/core"; +} from "aws-cdk-lib/aws-cloudfront"; +import { S3Origin } from "aws-cdk-lib/aws-cloudfront-origins"; +import { Bucket } from "aws-cdk-lib/aws-s3"; +import type { Construct as CdkConstruct } from "constructs"; +import { Duration } from "aws-cdk-lib"; +import { CfnOutput, RemovalPolicy } from "aws-cdk-lib"; import type { ConstructCommands } from "@lift/constructs"; import { AwsConstruct } from "@lift/constructs/abstracts"; import type { AwsProvider } from "@lift/providers"; diff --git a/src/plugin.ts b/src/plugin.ts index 8c5aeb23..0b006e82 100644 --- a/src/plugin.ts +++ b/src/plugin.ts @@ -3,7 +3,7 @@ import type { AwsIamPolicyStatements } from "@serverless/typescript"; import * as path from "path"; import { readFileSync } from "fs"; import { dump } from "js-yaml"; -import { DefaultTokenResolver, Lazy, StringConcat, Tokenization } from "@aws-cdk/core"; +import { DefaultTokenResolver, Lazy, StringConcat, Tokenization } from "aws-cdk-lib"; import type { FromSchema } from "json-schema-to-ts"; import type { ProviderInterface, StaticProviderInterface } from "@lift/providers"; import { AwsProvider, StripeProvider } from "@lift/providers"; diff --git a/src/providers/AwsProvider.ts b/src/providers/AwsProvider.ts index 6542d766..f6470f12 100644 --- a/src/providers/AwsProvider.ts +++ b/src/providers/AwsProvider.ts @@ -1,5 +1,5 @@ -import type { CfnOutput } from "@aws-cdk/core"; -import { App, Stack } from "@aws-cdk/core"; +import type { CfnOutput } from "aws-cdk-lib"; +import { App, Stack } from "aws-cdk-lib"; import { get, merge } from "lodash"; import type { AwsCfInstruction, AwsLambdaVpcConfig } from "@serverless/typescript"; import type { ProviderInterface } from "@lift/providers"; diff --git a/src/types/serverless.ts b/src/types/serverless.ts index 5bd6c8cd..d4ff66f1 100644 --- a/src/types/serverless.ts +++ b/src/types/serverless.ts @@ -1,5 +1,5 @@ import type { AWS } from "@serverless/typescript"; -import type { Stack } from "@aws-cdk/core"; +import type { Stack } from "aws-cdk-lib"; export type Hook = () => void | Promise; diff --git a/src/utils/getDefaultCfnFunctionAssociations.ts b/src/utils/getDefaultCfnFunctionAssociations.ts index a4205681..4076c5ab 100644 --- a/src/utils/getDefaultCfnFunctionAssociations.ts +++ b/src/utils/getDefaultCfnFunctionAssociations.ts @@ -1,4 +1,4 @@ -import type { CfnDistribution } from "@aws-cdk/aws-cloudfront"; +import type { CfnDistribution } from "aws-cdk-lib/aws-cloudfront"; interface CfnFunctionAssociation { EventType: string; diff --git a/test/utils/runServerless.ts b/test/utils/runServerless.ts index 61055563..a3f5abac 100644 --- a/test/utils/runServerless.ts +++ b/test/utils/runServerless.ts @@ -1,5 +1,5 @@ import path from "path"; -import { Names } from "@aws-cdk/core"; +import { Names } from "aws-cdk-lib"; import type originalRunServerless from "@serverless/test/run-serverless"; import setupRunServerlessFixturesEngine from "@serverless/test/setup-run-serverless-fixtures-engine"; import type { AWS } from "@serverless/typescript"; From 89f3a603af444fe2f8a70fa621ddd9c65913c10b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Barthelet?= Date: Wed, 27 Apr 2022 16:33:41 +0200 Subject: [PATCH 2/5] Update Cloudfront minimum TLS requirements from 2019 to 2021 --- test/unit/serverSideWebsite.test.ts | 2 +- test/unit/staticWebsites.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/unit/serverSideWebsite.test.ts b/test/unit/serverSideWebsite.test.ts index 5a28dfd8..47a541ca 100644 --- a/test/unit/serverSideWebsite.test.ts +++ b/test/unit/serverSideWebsite.test.ts @@ -337,7 +337,7 @@ describe("server-side website", () => { ViewerCertificate: { AcmCertificateArn: "arn:aws:acm:us-east-1:123456615250:certificate/0a28e63d-d3a9-4578-9f8b-14347bfe8123", - MinimumProtocolVersion: "TLSv1.2_2019", + MinimumProtocolVersion: "TLSv1.2_2021", SslSupportMethod: "sni-only", }, }, diff --git a/test/unit/staticWebsites.test.ts b/test/unit/staticWebsites.test.ts index 23610032..c60bfedb 100644 --- a/test/unit/staticWebsites.test.ts +++ b/test/unit/staticWebsites.test.ts @@ -192,7 +192,7 @@ describe("static websites", () => { ViewerCertificate: { AcmCertificateArn: "arn:aws:acm:us-east-1:123456615250:certificate/0a28e63d-d3a9-4578-9f8b-14347bfe8123", - MinimumProtocolVersion: "TLSv1.2_2019", + MinimumProtocolVersion: "TLSv1.2_2021", SslSupportMethod: "sni-only", }, }, From d4eac0af579948c64b390a446754915683894a99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Barthelet?= Date: Wed, 27 Apr 2022 16:34:20 +0200 Subject: [PATCH 3/5] Update VPC security group reference In order to provision AWS Provider VPC configuration, reference to security group was made using securityGroupName property from Security Group CDK construct. This property is deprecated and was replaced with the use of securityGroupId which generate a different Cloudformation intrinsic function --- test/unit/vpc.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/vpc.test.ts b/test/unit/vpc.test.ts index 45fb6395..1ece7eec 100644 --- a/test/unit/vpc.test.ts +++ b/test/unit/vpc.test.ts @@ -17,7 +17,7 @@ describe("vpc", () => { >; expect(vpcConfig).toHaveProperty("SecurityGroupIds"); expect((vpcConfig.SecurityGroupIds as AwsCfInstruction[])[0]).toMatchObject({ - Ref: computeLogicalId("vpc", "AppSecurityGroup"), + "Fn::GetAtt": [computeLogicalId("vpc", "AppSecurityGroup"), "GroupId"], }); expect(vpcConfig).toHaveProperty("SubnetIds"); expect(vpcConfig.SubnetIds).toContainEqual({ From 3089020b5da49292f4d3ab466e84ce2fcde6cba9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Barthelet?= Date: Wed, 27 Apr 2022 16:53:55 +0200 Subject: [PATCH 4/5] Prevent CDK from checking bootstrap version --- src/providers/AwsProvider.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/providers/AwsProvider.ts b/src/providers/AwsProvider.ts index f6470f12..aa645e7a 100644 --- a/src/providers/AwsProvider.ts +++ b/src/providers/AwsProvider.ts @@ -1,5 +1,5 @@ import type { CfnOutput } from "aws-cdk-lib"; -import { App, Stack } from "aws-cdk-lib"; +import { App, DefaultStackSynthesizer, Stack } from "aws-cdk-lib"; import { get, merge } from "lodash"; import type { AwsCfInstruction, AwsLambdaVpcConfig } from "@serverless/typescript"; import type { ProviderInterface } from "@lift/providers"; @@ -69,7 +69,11 @@ export class AwsProvider implements ProviderInterface { constructor(private readonly serverless: Serverless) { this.stackName = serverless.getProvider("aws").naming.getStackName(); this.app = new App(); - this.stack = new Stack(this.app); + this.stack = new Stack(this.app, undefined, { + synthesizer: new DefaultStackSynthesizer({ + generateBootstrapVersionRule: false, + }), + }); this.legacyProvider = serverless.getProvider("aws"); this.naming = this.legacyProvider.naming; this.region = serverless.getProvider("aws").getRegion(); From 995c6e48f485f8de81767dc9e6543e9752d410b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Barthelet?= Date: Wed, 27 Apr 2022 17:05:05 +0200 Subject: [PATCH 5/5] Remove support for Node 12 --- .github/workflows/ci.yml | 3 +-- package.json | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ab405ba7..c2c8068a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,10 +14,9 @@ jobs: strategy: matrix: node: - - "12.13.0" - 14 - 16 - - 17 + - 18 serverless: - "2.36.0" - "2" diff --git a/package.json b/package.json index cb291199..4c6ddb80 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,7 @@ "typescript": "^4.3.4" }, "engines": { - "node": ">=12.13 <18" + "node": ">=14.15.0 <19" }, "files": [ "/dist"