From 3ab87694203584cdfa208bf75e648e0e944f5e18 Mon Sep 17 00:00:00 2001 From: Ammar <56042290+ammarkarachi@users.noreply.github.com> Date: Tue, 20 Jul 2021 16:25:50 -0700 Subject: [PATCH] Revert "fix: upgrade node default runtime to 14 (#7700)" (#7763) This reverts commit 47968cc9c704ac1cffcbd0dbe40d164b1b1d48d6. --- .../pinpoint-cloudformation-template.json | 2 +- .../cloudformation-templates/auth-template.yml.ejs | 12 ++++++------ .../user-pool-group-template.json.ejs | 2 +- .../awscloudformation/assets/identifyCFNGenerate.js | 2 +- .../identify-template.json.ejs | 2 +- .../src/__tests__/migration/node.function.test.ts | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/packages/amplify-category-analytics/provider-utils/awscloudformation/cloudformation-templates/pinpoint-cloudformation-template.json b/packages/amplify-category-analytics/provider-utils/awscloudformation/cloudformation-templates/pinpoint-cloudformation-template.json index e6c0adcf6d2..71dd61aefcd 100644 --- a/packages/amplify-category-analytics/provider-utils/awscloudformation/cloudformation-templates/pinpoint-cloudformation-template.json +++ b/packages/amplify-category-analytics/provider-utils/awscloudformation/cloudformation-templates/pinpoint-cloudformation-template.json @@ -229,7 +229,7 @@ } }, "Handler": "index.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs12.x", "Timeout": "300", "Role": { "Fn::GetAtt": ["LambdaExecutionRole", "Arn"] diff --git a/packages/amplify-category-auth/resources/cloudformation-templates/auth-template.yml.ejs b/packages/amplify-category-auth/resources/cloudformation-templates/auth-template.yml.ejs index e623d9f03bc..77d2ff617b0 100644 --- a/packages/amplify-category-auth/resources/cloudformation-templates/auth-template.yml.ejs +++ b/packages/amplify-category-auth/resources/cloudformation-templates/auth-template.yml.ejs @@ -381,7 +381,7 @@ Resources: - ' }' - '};' Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - UserPoolClientRole @@ -507,7 +507,7 @@ Resources: Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - UserPoolClientRole @@ -659,7 +659,7 @@ Resources: - '} ' Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - UserPoolClientRole @@ -758,7 +758,7 @@ Resources: - '}' Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - UserPoolClientRole @@ -888,7 +888,7 @@ Resources: - ' }' - '};' Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - MFALambdaRole @@ -1048,7 +1048,7 @@ Resources: - ' }' - '};' Handler: index.handler - Runtime: nodejs14.x + Runtime: nodejs12.x Timeout: '300' Role: !GetAtt - OpenIdLambdaRole diff --git a/packages/amplify-category-auth/resources/cloudformation-templates/user-pool-group-template.json.ejs b/packages/amplify-category-auth/resources/cloudformation-templates/user-pool-group-template.json.ejs index db1f6935ab7..2a5e1d94023 100644 --- a/packages/amplify-category-auth/resources/cloudformation-templates/user-pool-group-template.json.ejs +++ b/packages/amplify-category-auth/resources/cloudformation-templates/user-pool-group-template.json.ejs @@ -248,7 +248,7 @@ } }, "Handler": "index.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs12.x", "Timeout": "300", "Role": { "Fn::GetAtt": [ diff --git a/packages/amplify-category-predictions/provider-utils/awscloudformation/assets/identifyCFNGenerate.js b/packages/amplify-category-predictions/provider-utils/awscloudformation/assets/identifyCFNGenerate.js index 8033570231b..1b03a7197dd 100644 --- a/packages/amplify-category-predictions/provider-utils/awscloudformation/assets/identifyCFNGenerate.js +++ b/packages/amplify-category-predictions/provider-utils/awscloudformation/assets/identifyCFNGenerate.js @@ -521,7 +521,7 @@ function generateLambdaAccessForRekognition(identifyCFNFile, functionName, s3Res }, }, Handler: 'index.handler', - Runtime: 'nodejs14.x', + Runtime: 'nodejs12.x', Timeout: '300', Role: { 'Fn::GetAtt': ['CollectionsLambdaExecutionRole', 'Arn'], diff --git a/packages/amplify-category-predictions/provider-utils/awscloudformation/cloudformation-templates/identify-template.json.ejs b/packages/amplify-category-predictions/provider-utils/awscloudformation/cloudformation-templates/identify-template.json.ejs index 8659f22907e..4e1663ca6e3 100644 --- a/packages/amplify-category-predictions/provider-utils/awscloudformation/cloudformation-templates/identify-template.json.ejs +++ b/packages/amplify-category-predictions/provider-utils/awscloudformation/cloudformation-templates/identify-template.json.ejs @@ -353,7 +353,7 @@ } }, "Handler": "index.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs12.x", "Timeout": "300", "Role": { "Fn::GetAtt": [ diff --git a/packages/amplify-e2e-tests/src/__tests__/migration/node.function.test.ts b/packages/amplify-e2e-tests/src/__tests__/migration/node.function.test.ts index a8eeec246fc..d1cebcf6e57 100644 --- a/packages/amplify-e2e-tests/src/__tests__/migration/node.function.test.ts +++ b/packages/amplify-e2e-tests/src/__tests__/migration/node.function.test.ts @@ -56,7 +56,7 @@ describe('nodejs version migration tests', () => { ); let authStackContent = fs.readFileSync(authStackFileName).toString(); - authStackContent = authStackContent.replace('nodejs14.x', 'nodejs10.x'); + authStackContent = authStackContent.replace('nodejs12.x', 'nodejs10.x'); fs.writeFileSync(authStackFileName, authStackContent, 'utf-8');