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

refactor: move unpackedImageSize to imgutil #1936

Merged
merged 1 commit into from
Feb 2, 2023

Conversation

davidhsingyuchen
Copy link
Contributor

@davidhsingyuchen davidhsingyuchen commented Jan 27, 2023

PR is a blocker of refactoring nerdctl (container) ps according to #1680.

Notes:

  • I thought about if unpackedImageSize should go into imgutil/snapshotter.go instead, but that file seems to be about the different snapshotters themselves, while unpackedImageSize is more like a utility function that happens to depend on snapshotter, just like snapshotter in the parameter list of GetExistingImage, so I put it into imgutil/imgutil.go eventually.
  • Also removed the corresponding duplicate code in pkg/cmd/image/list.go.

@Zheaoli Regarding #1821 (comment), please let me know if you've already started working on this, and I can close my PR accordingly. I created this PR because it's been a while since that comment, and I guess you may have been occupied by something else :)

Signed-off-by: Hsing-Yu (David) Chen [email protected]

Signed-off-by: Hsing-Yu (David) Chen <[email protected]>
@davidhsingyuchen davidhsingyuchen marked this pull request as ready for review January 27, 2023 22:06
Copy link
Member

@djdongjin djdongjin left a comment

Choose a reason for hiding this comment

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

LGTM, thanks

Copy link
Member

@Zheaoli Zheaoli left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks

@Zheaoli Zheaoli merged commit b2b0465 into containerd:main Feb 2, 2023
@davidhsingyuchen davidhsingyuchen deleted the move-unpackedImageSize branch February 2, 2023 18:20
@AkihiroSuda AkihiroSuda added this to the v1.3.0 (tentative) milestone Feb 4, 2023
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.

4 participants