cli: ability to pass context values through file
- Dominant language
- TypeScript
- Stars
- 105
- Forks
- 122
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 71
Description
### Describe the feature
Context variables allow passing parameters to the cdk command. But since they need to be specified individually, reruns become a challenge.
Keep track of what values have been used previously and pass them again.
If there are multiple environments it become even more challenging and tedious.
### Use Case
Reruns require me to remember and pass the same variables everytime. Also specifying each variable everytime is tedious.
### Proposed Solution
The ability to store these values in a json file and passing it to the cli would be great feature for reusability and maintenance.
`cdk deploy --context-file cdk.dev.json`
or
`cdk deploy --context-file cdk.stage.json -c "vpcEnv=qa"`
### Other Information
_No response_
### Acknowledgements
- [X] I may be able to implement this feature request
- [ ] This feature might incur a breaking change
### CDK version used
2.62.2
### Environment details (OS name and version, etc.)
MacOS Ventura
Contributor guide
Assessment
This issue has not been assessed yet.