Skip to content

Commit

Permalink
Merge branch 'main' into serverless-plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
72636c committed Feb 1, 2024
2 parents f057c84 + e285d20 commit ad1cf96
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 11 deletions.
9 changes: 9 additions & 0 deletions packages/infra/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# @seek/aws-codedeploy-infra

## 1.0.0

### Major Changes

- **LambdaDeployment:** Add construct ([#26](https://github.com/seek-oss/aws-codedeploy-hooks/pull/26))

- **HookStack:** Add construct ([#26](https://github.com/seek-oss/aws-codedeploy-hooks/pull/26))
19 changes: 10 additions & 9 deletions packages/infra/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,16 @@ In a CDK stack:
+ import { LambdaDeployment } from '@seek/aws-codedeploy-infra';
import { aws_lambda_nodejs } from 'aws-cdk-lib';

const lambdaFunction = new aws_lambda_nodejs.NodejsFunction(
this,
'MyLambdaFunction',
{
// ...
},
);

+ new LambdaDeployment(this, 'MyLambdaDeployment', { lambdaFunction });
const lambdaFunction = new aws_lambda_nodejs.NodejsFunction(this, 'Function', {
// ...
});

+ const lambdaDeployment = new LambdaDeployment(this, 'Deployment', {
+ lambdaFunction,
+ });

- lambdaFunction.addEventSource(source);
+ lambdaDeployment.alias.addEventSource(source);
```

The `LambdaDeployment` construct creates a CodeDeploy application and deployment group for your Lambda function,
Expand Down
4 changes: 2 additions & 2 deletions packages/infra/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@seek/aws-codedeploy-infra",
"version": "0.0.0",
"private": true,
"version": "1.0.0",
"private": false,
"license": "MIT",
"sideEffects": false,
"main": "./lib/index.js",
Expand Down

0 comments on commit ad1cf96

Please sign in to comment.