Conversation
thaJeztah
left a comment
There was a problem hiding this comment.
LGTM (left some suggestions, but no blockers)
| @@ -254,8 +255,9 @@ type imageFilterFunc func(image images.Image) bool | |||
| // setupFilters constructs an imageFilterFunc from the given imageFilters. | |||
| // | |||
| // TODO(thaJeztah): reimplement filters using containerd filters: see https://github.com/moby/moby/issues/43845 | |||
There was a problem hiding this comment.
Are there (more) filters we can delegate to containerd? (Otherwise we could remove this comment) - not a blocker though we can always remove in a follow-up
There was a problem hiding this comment.
Hm, dangling can be done with c8d too.
Not sure about time and how c8d would compare them. Will check.
There was a problem hiding this comment.
Let's keep the ticket open then (feel free to leave a comment there on other filters we could still implement using containerd to improve things)
There was a problem hiding this comment.
Yeah currently we can't do any more (except dangling). Posted a code that specified available properties in the issue.
There was a problem hiding this comment.
Crap, dangling is fun too. There's no fuzzy negation, so we'd need something like this: https://github.com/moby/moby/blob/master/.github/workflows/buildkit.yml#L123 😅
There was a problem hiding this comment.
😬 yeah, let's not do that for now 😂
| // | ||
| // TODO(thaJeztah): reimplement filters using containerd filters: see https://github.com/moby/moby/issues/43845 | ||
| func (i *ImageService) setupFilters(ctx context.Context, imageFilters filters.Args) (imageFilterFunc, error) { | ||
| func (i *ImageService) setupFilters(ctx context.Context, imageFilters filters.Args) ([]string, imageFilterFunc, error) { |
There was a problem hiding this comment.
Not a blocker (as it's not exported), but we could consider to use either named return variables (to "document" what they are), or update the GoDoc of the function to describe what it returns.
There was a problem hiding this comment.
Changed parameters to be named and described them in Godoc.
61d4383 to
8ab18ae
Compare
rumpl
left a comment
There was a problem hiding this comment.
LGTM after the fix for the equals operator
8ab18ae to
d24bc42
Compare
|
Hmm wait, isn't the fork behavior for |
|
For example, Ubuntu: This is on "non-c8d Docker": But it won't have the same result with this implementation because ubuntu image doesn't have these labels attached to the containerd image object (labels are empty): So, unless we want to populate containerd Image object's |
d24bc42 to
9b6249a
Compare
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
9b6249a to
ba47cdc
Compare
reference and label! filterreference
|
Moved the |
- What I did
Implemented
referencefilter.Note: The fork implementation used fuzzy match for
referencefilter, but this isn't consistent with the graphdriver Docker.- How I did it
- How to verify it
$ docker images REPOSITORY TAG IMAGE ID CREATED SIZE alpine latest 124c7d270790 About a minute ago 3.27MB busybox latest b5d6fe071263 2 seconds ago 2.01MB $ docker images --filter 'reference=busybox' REPOSITORY TAG IMAGE ID CREATED SIZE busybox latest b5d6fe071263 8 seconds ago 2.01MB $ docker images busybox REPOSITORY TAG IMAGE ID CREATED SIZE busybox latest b5d6fe071263 10 seconds ago 2.01MB $ docker images alpine REPOSITORY TAG IMAGE ID CREATED SIZE alpine latest 124c7d270790 About a minute ago 3.27MB- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)