Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Add image load and container run quiet mode #3551

Merged

Conversation

austinvazquez
Copy link
Contributor

@austinvazquez austinvazquez commented Oct 15, 2024

Issue

Split from #3537

Description

This change adds -q|--quiet flag on nerdctl load, nerdctl container create, and nerdctl container run commands to suppress image pull and load output.

Testing

  1. Manual tested behavior aligned with Docker 25.
$ docker load -q -i alpine-latest.tar 
Loaded image: alpine:latest
$ _output/nerdctl load -q -i alpine-latest.tar 
Loaded image: alpine:latest
$ 
$ docker run --rm --quiet alpine:latest echo "test run quiet"
test run quiet
$ _output/nerdctl run --rm --quiet alpine:latest echo "test run quiet"
test run quiet
$ 
  1. Added integration tests

Signed-off-by: Austin Vazquez <macedonv@amazon.com>
@apostasie
Copy link
Contributor

Not necessarily in this PR, but I am wondering if --quiet should be a global flag - given the fact we do need to pull missing content on many operations (convert, tag, commit, push) (containerd/containerd#8973)

Copy link
Member

@AkihiroSuda AkihiroSuda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@AkihiroSuda AkihiroSuda merged commit 1123a60 into containerd:main Oct 15, 2024
22 checks passed
@AkihiroSuda AkihiroSuda added this to the v2.0.0 milestone Oct 15, 2024
@AkihiroSuda
Copy link
Member

Not necessarily in this PR, but I am wondering if --quiet should be a global flag - given the fact we do need to pull missing content on many operations (convert, tag, commit, push) (containerd/containerd#8973)

Probably this is safe, but Docker didn't do this

@austinvazquez austinvazquez deleted the support-load-container-quiet-mode branch October 15, 2024 20:02
@apostasie
Copy link
Contributor

Not necessarily in this PR, but I am wondering if --quiet should be a global flag - given the fact we do need to pull missing content on many operations (convert, tag, commit, push) (containerd/containerd#8973)

Probably this is safe, but Docker didn't do this

I guess containerd lazy pulling / remote snapshotters does not apply for Docker, which is why they do not have this class of problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants