Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[aws-ecr-assets] DockerImageAsset: Suppress docker build output #29555

Open
2 tasks
nikolic-milan opened this issue Mar 20, 2024 · 2 comments
Open
2 tasks

[aws-ecr-assets] DockerImageAsset: Suppress docker build output #29555

nikolic-milan opened this issue Mar 20, 2024 · 2 comments
Labels
@aws-cdk/aws-ecr-assets Related to AWS CDK Docker Image Assets effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2

Comments

@nikolic-milan
Copy link

Describe the feature

I am using ecr_assets.DockerImageAsset to build a docker image from a Dockerfile. I would like a way to suppress the output of this. The output from docker interferes with the normal out of CDK, below example of how it looks. Ugly and more importantly confusing.
image

It would be nice, if either one could disable it, our somehow guarantee that they don't interfere, build the image and then once done and all the logs are out, start with the cdk output.

Use Case

I just think it would be better if one could suppress the output and just have the regular CDK output. It's going to be easier when debugging, and if I need to debug the build image process I could temporarily remove the flag.

Proposed Solution

docker build has a flag that suppresses outputs, -q --quite. A solution similar to how cache_disabled is implemented.
An optional boolean parameter that adds -q flag to the docker build command.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.130.0

Environment details (OS name and version, etc.)

Windows 11

@nikolic-milan nikolic-milan added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Mar 20, 2024
@github-actions github-actions bot added the @aws-cdk/aws-ecr-assets Related to AWS CDK Docker Image Assets label Mar 20, 2024
@pahud
Copy link
Contributor

pahud commented Mar 20, 2024

Makes sense for me. Adding this as a p2 feature request and we welcome the pull requests.

@pahud pahud added p2 effort/medium Medium work item – several days of effort and removed needs-triage This issue or PR still needs to be triaged. labels Mar 20, 2024
@kaleko
Copy link

kaleko commented Nov 25, 2024

Any update on this feature? My users are confused during cdk deploy because the verbose docker output pushes the y/n user input request out of the window, so they think the deployment is hanging.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
@aws-cdk/aws-ecr-assets Related to AWS CDK Docker Image Assets effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2
Projects
None yet
Development

No branches or pull requests

3 participants