aws / aws-cli

Universal Command Line Interface for Amazon Web Services
Other
15.46k stars 4.1k forks source link

[feat] output progress on `aws cloudformation wait` #3208

Open andreineculau opened 6 years ago

andreineculau commented 6 years ago

Several CI/CD environment e.g. Travis check for hanged executions based on stdout output, or the lack of it actually. Travis in particular has a way to extend the timeout, but that is a workaround, not a solution.

Deploying an API Gateway or a CloudFront instance can take a really long time, and aws cloudformation wait does not output anything at all.

Please consider changing the current behaviour, or add a flag e.g. --progress that would print something to stdout every 30s=poll. A dot. A "Waiting for change-set to reach status CREATE_COMPLETE..." on a new line. Something.

kyleknap commented 6 years ago

Marking as feature request. Seems reasonable to me. I think this could apply to all wait commands.

pmartindev commented 6 years ago

This would be a great feature to have! It seems necessary when running ci/cd systems.

hoegertn commented 5 years ago

It would even be better if the CloudFormation events would be printed to stdout. I would then see the progress of the stack in my CI/CD logs.

andreineculau commented 5 years ago

@hoegertn true that, but the list of events can be really long (I'm saying that with Travis in mind, where you have a limit of how much logging you can do, which is 4MB if memory holds).

What we have done is print only relevant FAILED/ROLLBACK events if the stack provisioning fails https://github.com/tobiipro/support-firecloud/blob/master/bin/aws-cloudformation-cu-stack#L209-L216

ghost commented 5 years ago

I think a parameter like --tail would be great.

aapjeisbaas commented 4 years ago

I also wanted wanted something like a log tail for cfn deployments in pipeline and made a small bash wrapper to do this: https://tech.aapjeisbaas.nl/display-aws-cloudformation-logs-in-pipelines.html

A --tail or --follow would be awesome, if there is enough interest I would love help out by creating this in a fork.