-
Notifications
You must be signed in to change notification settings - Fork 574
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
E3037 not triggered for hard coded key values in AWS::ECS::TaskDefinition #2930
Comments
This is an interesting one. We will have to create a new rule for this. So E3037 will flag on all elements not just one key. So this should have flagged. Environment:
- Name: DUPE_KEY
Value: 'firstval'
- Name: DUPE_KEY
Value: 'firstval' The resulting task definition drops the secondary Name(s) which isn't an ideal experience. Going to ask some internal people on how we should handle this. "environment": [
{
"name": "DUPE_KEY",
"value": "firstval"
}
] |
The AWS result is worse than that. Out of 7 stacks we had installed through different accounts / regions, one of them, and only after one update, used the first value. |
I've included a fix for this in v1. I still have some work to do for adding this to Tags. |
CloudFormation Lint Version
0.83.0
What operating system are you using?
Fedora
Describe the bug
E3037 does not get triggered for AWS::ECS::TaskDefinition, ContainerDefinitions -> Environment for hard coded keys
In the attached zip are two templates. Both of them should trigger the E3037 error however the one with environment keys
`Environment:
Value: 'firstval'
Value: 'secondval'
`
does not error
e3037-recreate.zip
Expected behavior
E3037 should be triggered for hard coded keys
Reproduction template
The text was updated successfully, but these errors were encountered: