Commit Graph

14 Commits

Author SHA1 Message Date
Tianon Gravi b20e82cb0d Add new "bashbrew remote arches" command
This command will, given a remote image reference, look up the list of platforms from it and match them to supported bashbrew architectures (providing content descriptors for each).

Also, refactor registry code to be more correct: previously, this couldn't fetch from Docker without `DOCKERHUB_PUBLIC_PROXY` (see `registry-1.docker.io` change) and was ignoring content digests.  Now it works correctly with or without `DOCKERHUB_PUBLIC_PROXY`, verifies the size of every object it pulls, verifies the digest, _and_ should continue working with the in-progress Moby containerd-integration (where the local image ID becomes the digest of the manifest or index instead of the digest of the config blob as it is today).
2022-11-16 15:31:47 -08:00
Tianon Gravi f54c8e397a Rewrite "bashbrew children" and "bashbrew parents"
This time, they are distinct implementations because the problem they are solving is inherently different.

For listing children of a given name, we *have* to walk the entire library (since we only have tag -> FROM mappings, not the reverse, which is fundamentally the question that "children" answers).

On the flip side, listing the parents of a given name is as straightforward as looking up the FROM values and walking until we can't anymore.

In my own testing, these new implementations are significantly more correct, and handle more edge cases (including things we couldn't support before like `bashbrew children --depth=1 scratch`, `bashbrew children mcr.microsoft.com/windows/servercore`, etc).

They also more correctly handle edge cases like tags that are `FROM` a "`SharedTag`" such that they don't walk up/down both sides of the tree (for example, `orientdb:3.2` -> `FROM eclipse-temurin:8-jdk`, which is both Windows *and* Linux, even though `orientdb:3.2` is Linux-only).
2022-11-14 14:32:20 -08:00
Dave Henderson 7a3d9de20f
Update containerd to avoid CVEs
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2022-04-15 20:25:35 -04:00
Tianon Gravi 81270c867e Update dependencies 2021-11-30 12:29:41 -08:00
Dave Henderson 8f2d87dc13
Update some dependencies to avoid CVEs
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2021-11-05 19:25:59 -04:00
Tianon Gravi 4c86d18022 Update pault.ag/go/debian to v0.11.0 2021-02-08 11:02:41 -08:00
Tianon Gravi a6373f407d Use containerd resolver/fetcher to query registry for "skip checking" 2020-09-15 15:50:00 -07:00
Tianon Gravi e609341812 Update Go dependencies 2020-08-21 14:43:01 -07:00
Tianon Gravi 5efa400516 Update "pault.ag/go/debian" to fix https://github.com/paultag/go-debian/issues/104 2020-08-21 14:35:45 -07:00
Tianon Gravi 143301cc9e Merge github.com/docker-library/go-dockerlibrary into bashbrew
This adjusts import paths, go.mod, and adds a new "Dockerfile.test" to run the unit tests.
2020-08-19 16:21:07 -07:00
Tianon Gravi 013567335e Update to github.com/go-git/go-git v5.1.0
See https://github.com/go-git/go-git/releases/tag/v5.1.0 for more details.
2020-05-26 12:09:00 -07:00
Tianon Gravi daa5333f67 Use new go-git functionality to fetch commits
This avoids shelling out by using the implementation from 8ecd388ae1, which is going to be much more performant.
2020-05-11 11:21:57 -07:00
Tianon Gravi 64bfd4ce30 Update to github.com/go-git/go-git v5 2020-05-06 11:42:58 -07:00
Tianon Gravi 5425126232 Move Go code to root of the repo 2020-04-24 11:48:08 -07:00