Skip to content

Commit

Permalink
using full arn
Browse files Browse the repository at this point in the history
  • Loading branch information
akinsola-guardian committed May 16, 2024
1 parent 828ad4b commit 5e4d9d9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cdk/lib/__snapshots__/monitoring.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ exports[`The Monitoring stack matches the snapshot 1`] = `
},
"Runtime": "nodejs18.x",
"RuntimeManagementConfig": {
"RuntimeVersionArn": "0cdcfbdefbc5e7d3343f73c2e2dd3cba17d61dea0686b404502a0c9ce83931b9",
"RuntimeVersionArn": "arn:aws:lambda:eu-west-1::runtime:0cdcfbdefbc5e7d3343f73c2e2dd3cba17d61dea0686b404502a0c9ce83931b9",
"UpdateRuntimeOn": "Manual",
},
"Tags": [
Expand Down
4 changes: 3 additions & 1 deletion cdk/lib/monitoring.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ export class Monitoring extends GuStack {
resources: ['*'],
});

const runTimeManagement = `arn:aws:lambda:${region}::runtime:0cdcfbdefbc5e7d3343f73c2e2dd3cba17d61dea0686b404502a0c9ce83931b9`

const monitoringLambdaFunction = new GuLambdaFunction(
this,
lambdaBaseName,
Expand All @@ -47,7 +49,7 @@ export class Monitoring extends GuStack {
fileName: `${lambdaBaseName}-lambda-${region}.zip`,
handler: 'index.handler',
runtime: Runtime.NODEJS_18_X,
runtimeManagementMode: RuntimeManagementMode.manual("0cdcfbdefbc5e7d3343f73c2e2dd3cba17d61dea0686b404502a0c9ce83931b9"),
runtimeManagementMode: RuntimeManagementMode.manual(runTimeManagement),
timeout: Duration.seconds(300),
memorySize: 2048,
initialPolicy: [policyStatement],
Expand Down

1 comment on commit 5e4d9d9

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage report

St.
Category Percentage Covered / Total
🟢 Statements 91.04% 254/279
🟢 Branches 81.67% 98/120
🟢 Functions 88.57% 62/70
🟢 Lines 90.74% 245/270

Test suite run success

331 tests passing in 16 suites.

Report generated by 🧪jest coverage report action from 5e4d9d9

Please sign in to comment.