ParameterOverrides string can fail CloudFormation character limit
See original GitHub issueIt is possible to generate a CloudFormation template with a value in the CodePipeline.Stages.Actions.Configuration.ParameterOverrides
field that violates the maximum character limit.
Reproduction Steps
new CloudFormationCreateUpdateStackAction({
parameterOverrides: {
test: "somethingOver1000Characters..."
}
});
Error Log
Pipeline (PipelineXYZ) 1 validation error detected: Value at 'pipeline.stages.4.member.actions.1.member.configuration' failed to satisfy constraint: Map value must satisfy constraint: [Member must have length less than or equal to 1000, Member must have length greater than or equal to 1]
Environment
- CLI Version : aws-cli/1.16.130 Python/3.7.4 Darwin/18.7.0 botocore/1.12.120
- Framework Version: 1.20
- OS : macOS
- Language : TypeScript
Other
As a possible solution, it seems the JSON to string transformation performed here could be adapted to make us of the Fn::Join
function.
Looking at the tests it would suggest this is already being done but I have not been able to generate a CFN template that uses Fn::Join
as asserted here.
This is 🐛 Bug Report
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:6 (6 by maintainers)
Top Results From Across the Web
How to work around Cfn action's character limit in CodePipeline
If I look at the YAML output from cdk synth , the ParameterOverrides property comes out to 1351 characters. So that's a problem....
Read more >AWS CloudFormation configuration properties reference
There is a maximum size limit of 1 kilobyte for the JSON object that can be stored in the ParameterOverrides property. We recommend...
Read more >CloudFormation — botocore 1.11.4 documentation - AWS
If you don't, subsequent stack updates might fail, and the stack will become unrecoverable. ... You can specify a maximum of 128 characters...
Read more >AWS CloudFormation (version v1.*.*) - Transposit
A stack goes into the UPDATE_ROLLBACK_FAILED state when AWS CloudFormation cannot roll back all changes after a failed stack update. For example, you...
Read more >How to reduce your CloudFormation template size
You can reduce CloudFormation template size with e.g. a preprocessor ... failed to satisfy constraint: Member must have length less than or ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
All fixed, thanks @skinny85!
No problem, let me know if that fixes your issue!