1
0
mirror of https://github.com/containers/image.git synced 2025-04-18 19:44:05 +03:00

5779 Commits

Author SHA1 Message Date
renovate[bot]
041e6abfe5
fix(deps): update module golang.org/x/term to v0.30.0
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-13 17:48:26 +00:00
Miloslav Trmač
4e32a672d2
Merge pull request #2777 from containers/renovate/go-golang.org-x-net-vulnerability
chore(deps): update module golang.org/x/net to v0.36.0 [security]
2025-03-13 18:44:07 +01:00
renovate[bot]
e433f09c7d
chore(deps): update module golang.org/x/net to v0.36.0 [security]
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-13 17:21:19 +00:00
Miloslav Trmač
2c3e492ad6
Merge pull request #2775 from mtrmac/go1.23
Take advantage of new features in Go 1.23
2025-03-13 17:34:47 +01:00
Miloslav Trmač
8dabf442db Remove obsolete build tag syntax
per (go fix ./...).

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:20:16 +01:00
Miloslav Trmač
b1d309cce2 Return an iterator from authKeyLookupOrder
... so that we don't have to allocate a single-use array

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:18:06 +01:00
Miloslav Trmač
2f17a838a6 Generalize authKeyForKey into authKeyLookupOrder
... so that it handles the legacy path as well.
This will help future refactoring to use an iter.Seq.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:17:55 +01:00
Miloslav Trmač
690cc1b17c Use slices.Backward instead of manual indexing
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:17:48 +01:00
Miloslav Trmač
6336a84adf Use slices.Backward and append instead of manually indexing
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:17:35 +01:00
Miloslav Trmač
51d3a1c0ea Replace Set.AddSlice with Set.AddSeq, use it in more places
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:17:18 +01:00
Miloslav Trmač
76ad3e74fc Iterate over v1 data backward to build the v2 result in O(N) instead of O(N^2)
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:17:02 +01:00
Miloslav Trmač
01036eb5bd Avoid an allocation when iterating over WWW-Authenticate headers
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:16:50 +01:00
Miloslav Trmač
8dbcd05803 Rely on LoadX509KeyPair populating Certificate.Leaf
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:16:45 +01:00
Miloslav Trmač
96d0155f7e Use the standard-library sequence version of maps.Keys
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:16:29 +01:00
Miloslav Trmač
bc6b35d0c9 Replace Set.Values with a non-allocating Set.All
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 20:16:03 +01:00
Miloslav Trmač
4c5a86a9eb
Merge pull request #2774 from mtrmac/go1.23-minimal
Update to Go 1.23
2025-03-12 19:56:29 +01:00
Miloslav Trmač
a6c46e5d5c Update to Go 1.23
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-12 19:24:51 +01:00
Miloslav Trmač
6796620c7b
Merge pull request #2773 from containers/renovate/golangci-golangci-lint-1.x
chore(deps): update dependency golangci/golangci-lint to v1.64.7
2025-03-12 18:40:23 +01:00
renovate[bot]
c8cf826ecc
chore(deps): update dependency golangci/golangci-lint to v1.64.7
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-12 16:35:48 +00:00
Miloslav Trmač
e268baf43e
Merge pull request #2764 from warjiang/feat/proxy
Add proxy for dockerClient
2025-03-12 17:35:20 +01:00
warjiang
4d39b3e2c6 feat: add proxy for http client in dockerClient
Signed-off-by: warjiang <1096409085@qq.com>
2025-03-12 08:12:07 +08:00
Miloslav Trmač
d84dbab374
Merge pull request #2709 from mtrmac/content-length
Don't silently ignore errors determining size in TryReuseBlob
2025-03-11 20:40:52 +01:00
Miloslav Trmač
4dd6f6eeb7 Don't silently ignore errors determining size in TryReuseBlob
When looking for inexact matches, this will cause the matches to be skipped.
When checking for an exact match, this will cause an upload failure;
we don't have any other way to handle pre-existing blobs on the destination.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 20:10:11 +01:00
Miloslav Trmač
99996a1a92
Merge pull request #2756 from mtrmac/jsonschema
Migrate from github.com/xeipuuv/gojsonschema to github.com/santhosh-tekuri/jsonschema/v5
2025-03-11 20:04:41 +01:00
Miloslav Trmač
012524f942 Tidy an indirect depdendency in go.mod
Should not change behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:53:11 +01:00
Miloslav Trmač
a7a56efcfd Migrate from github.com/xeipuuv/gojsonschema to github.com/santhosh-tekuri/jsonschema/v5
github.com/xeipuuv/gojsonschema has last had a commit in Oct 2020.

So, follow what github.com/opencontainers/image-spec did, and move to
the same library that project uses.

Note that github.com/santhosh-tekuri/jsonschema/v6 already exists,
but the goal is to decrease the dependency surface (to the little extent
this matters, it's at most a test dependency anyway), so we prioritize
using the older version.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:52:58 +01:00
Miloslav Trmač
6f1abf0bf6
Merge pull request #2767 from mtrmac/transport-corner-cases
Improve handling and documentation of various transport reference corner cases
2025-03-11 18:41:16 +01:00
Miloslav Trmač
67490aee1f Improve transport syntax documentation
The same thing is already said a few lines below.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:11:39 +01:00
Miloslav Trmač
866803c979 Beautify doc strings
Should not change behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:11:31 +01:00
Miloslav Trmač
16448098a9 Document, at least minimally, that image == "" in OCI references is handled specially
Should not change behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:11:23 +01:00
Miloslav Trmač
a0f1cc18e2 Tighten the input validation of NewIndexReference
Reject NewIndexReference with a "missing" index value of -1;
callers can use the other NewReference instead.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:11:15 +01:00
Miloslav Trmač
19bcd59492 Explicitly reject daemon.NewReference with no values
They can't be used anyway (destinations require a reference,
and sources panic), so fail cleanly.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:11:07 +01:00
Miloslav Trmač
a8818506de Make a part of TestNewIndexReference table-based
Should not change (test) behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-11 18:10:55 +01:00
Miloslav Trmač
dcc9a83d6c
Merge pull request #2769 from mtrmac/storage-catchup
Update c/storage after https://github.com/containers/storage/pull/2276
2025-03-11 18:01:05 +01:00
Miloslav Trmač
fea8dd2f75 Merge tag 'v5.34.2' into storage-catchup
v5.34.2
2025-03-11 17:35:48 +01:00
Miloslav Trmač
600e8fdcea Update c/storage after https://github.com/containers/storage/pull/2276
... so that the referenced version is larger than 1.57.2 required by Skopeo,
and we don't downgrade and lose a required API.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-10 17:17:22 +01:00
Miloslav Trmač
0cf7de7e11
Merge pull request #2765 from TomSweeneyRedHat/dev/tsweeney/bumptov5.34.2
[release-5.34] Bump c/storage to v1.57.2, c/image to v5.34.2
2025-03-10 17:14:30 +01:00
tomsweeneyredhat
558f1f8757 [release-5.34] Bump to c/image v5.34.2
Bump to c/image v5.34.2

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
v5.34.2
2025-03-06 19:56:23 -05:00
tomsweeneyredhat
71bd224363 [release-5.34] Bump c/storage to v1.57.2
Bump c/storage to v1.57.2 to force idm map private
propacation per https://github.com/containers/storage/pull/2269

This is targeted for RHEL 9.6/10.0 ZeroDay.

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-03-06 19:48:35 -05:00
Miloslav Trmač
12497efe55
Merge pull request #2758 from warjiang/fix/typo-error
fix: typo err and grammar err
2025-03-06 16:41:30 +01:00
dingwenjiang
56e64f4ee5 fix: typo err and grammar err
Signed-off-by: warjiang <1096409085@qq.com>
2025-03-06 07:36:12 +08:00
Miloslav Trmač
02c8d65a46
Merge pull request #2757 from containers/renovate/github.com-docker-docker-credential-helpers-0.x
fix(deps): update module github.com/docker/docker-credential-helpers to v0.9.2
2025-03-05 22:26:59 +01:00
renovate[bot]
91b2b1158a
fix(deps): update module github.com/docker/docker-credential-helpers to v0.9.2
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-04 21:44:44 +00:00
Miloslav Trmač
1b336cac24
Merge pull request #2573 from kolyshkin/misc
Misc small nits to CI and build
2025-03-04 22:43:48 +01:00
Kir Kolyshkin
931070e8b8 Makefile: mark all phony targets as such
Quite a few phony targets were not marked as such. Fix this.

While at it, let's mark those individually, in place, so it's easier
to remember and check.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2025-03-04 12:40:49 -08:00
Kir Kolyshkin
73763ea96d .codespellrc: exclude directories with test data
Instead of excluding just the *.gpg files, let's exclude directories
containing those (and similar) files which should not be subjected
to spell checker.

This makes codespell run faster and fixes the following warning:

> WARNING: Cannot decode file using encoding "utf-8": ./signature/simplesigning/testdata/private-keys-v1.d/A0E6EC3A2963DC2D19E9C24E4E6DD232E6BBE1CD.key
> WARNING: Trying next encoding "iso-8859-1"

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2025-03-04 12:37:04 -08:00
Kir Kolyshkin
fd7479fe6a Makefile,.cirrus.yml: remove obsoleted build tag
Since commit 8ca60c5d we use c/storage with devicemapper driver removed,
so libdm_no_deferred_remove is no longer in use.

Remove it.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2025-03-04 12:37:04 -08:00
Miloslav Trmač
c43e62eed2
Merge pull request #2732 from mtrmac/cleanups
Microoptimize an API use per gopls modernize
2025-03-04 19:42:23 +01:00
Miloslav Trmač
08ac56d01e Microoptimize an API use per gopls modernize
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2025-03-04 19:10:50 +01:00
Miloslav Trmač
67693bb318
Merge pull request #2752 from containers/renovate/github.com-opencontainers-image-spec-1.x
fix(deps): update module github.com/opencontainers/image-spec to v1.1.1
2025-03-04 19:05:44 +01:00