Skip to content

Commit

Permalink
Simplify with addAlias
Browse files Browse the repository at this point in the history
  • Loading branch information
72636c committed Jan 6, 2024
1 parent 7af3e75 commit 6e9c1c7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions template/lambda-sqs-worker-cdk/infra/appStack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,7 @@ export class AppStack extends Stack {
description: `Updated at ${new Date().toISOString()}`,
});

const alias = new aws_lambda.Alias(this, 'worker-live-alias', {
aliasName: 'live',
version: worker.currentVersion,
const alias = worker.addAlias('live', {
description: 'The Lambda version currently receiving traffic',
});

Expand Down

0 comments on commit 6e9c1c7

Please sign in to comment.