The Serverless Rules are a compilation of rules to validate infrastructure as code template against recommended practices. This currently provides a module for cfn-lint and a plugin for tflint.
PUBLIC PREVIEW: this project is currently in public preview to get feedback from the serverless community. APIs, tools, and rules might change between the beginning of public preview and version 1.
You can find a list of currently supported rules in the documentation.
For cfn-lint
# To use this project with cfn-lint, you need to install the cfn-lint-serverless python module
pip install cfn-lint cfn-lint-serverless
# You can then run cfn-lint with the additional rules
cfn-lint my_template.yaml -a cfn_lint_serverless.rules
For tflint
You can add the aws-serverless
plugin to your .tflint.hcl configuration file:
plugin "aws-serverless" {
enabled = true
version = "0.1.0"
source = "github.com/aws-samples/serverless-rules/tflint-ruleset-aws-serverless"
}
See CONTRIBUTING to learn how to contribute to this project.
See CONTRIBUTING for more information.
This library is licensed under the MIT-0 License. See the LICENSE file.