Azure / Azure/deployment-stacks
[feature] stack-whatif - detailed exit code for the azure cli
- Dominant language
- Bicep
- Stars
- 101
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
**Is your feature request related to a problem? Please describe.**
Within our automated deployment flows we use `stack-whatif` to see the changes before deploying the stack.
In addition after the `stack-whatif` we have in some (critical) cases a human approval. After that approval the deployment takes effect.
When there are no changes. The human approval and the actual deployment are not necessary to be invoked.
When using other IaC tools (e.g.) `terraform` we already have implemented `if` conditions related to changes.
So if there are no changes we do not trigger the human approval and the deployment. This is reducing run time and also we do not interact with the Azure API (for the deployment) which in some cases can lead to concurrency and throttling issues.
**Describe the solution you'd like**
Some information within the output (e.g. exit code) would help.
As an example `terraform` has different exit codes (which can be enabled by flag `-detailed-exitcode`)
https://developer.hashicorp.com/terraform/cli/commands/plan#detailed-exitcode
This would help to get the information if changes are present or not.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by running the stack-whatif command and reading its current output and exit behavior. Compare the requested behavior with Terraform's detailed exit-code documentation; done means automation can distinguish no changes from changes after a what-if run without relying only on text output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure
- Domain
- cli, cloud
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100