Serverless Framework plugin that adds a deletion retain policy on aws lambda logs
-
To use this serverless plugin, you must first install it as a dependency.
Run
npm install --save-dev @xoi/serverless-log-keeper
oryarn add --dev @xoi/serverless-log-keeper
-
Add the plugin to your
serverless.yml
and add its configuration properties[...] region: us-east-2 plugins: - '@xoi/serverless-log-keeper' logkeeper: keepLambdaLogs: true [...]
-
Continue using Serverless as you normally would! Logkeeper will automatically add a deletion policy of retain to each /aws/lambda LogGroup
All configuration is done in serverless.yml at the root level under the logkeeper
property.
Here are the possible configuration options:
Configuration Key | Required? | Default | Description |
---|---|---|---|
keepLambdaLogs | Yes | N/A | A boolean that determines if we're going to retain lambda logs or not |
We welcome all contributors with open arms! See CONTRIBUTING.md