- Le plus récent
- Le plus de votes
- La plupart des commentaires
sam validate
does not provide an out-of-the-box feature to ignore specific warnings or errors based on their ID directly in the command or through a configuration file. The primary purpose of sam validate is to check the syntax and basic structure of the SAM template, not to provide extensive linting capabilities. For this reason, if sam validate returns a non-zero exit code due to a warning you wish to ignore, you might need to consider alternative approaches.
cfn-lint
is a more flexible tool when it comes to linting CloudFormation templates, including SAM templates in YAML or JSON format. It allows for extensive customization of the linting process, including ignoring specific rules. To ignore specific checks with cfn-lint, you can use the --ignore-checks
option followed by the IDs of the checks you want to ignore. For example:
cfn-lint template.yaml --ignore-checks W3002 W3045
Contenus pertinents
- demandé il y a 2 mois
- demandé il y a un an
- demandé il y a un an
- AWS OFFICIELA mis à jour il y a 2 ans
- AWS OFFICIELA mis à jour il y a 4 mois
- AWS OFFICIELA mis à jour il y a 2 ans
Thank you!
Worked as a charm after also adding a
pip install cfn-lint
in my Github action