Clark Boylan e43952f542 Handle pruning of manifest lists
There are two types of manifest objects that the pruning process will
list and consider as valid if their age is less than the timeout. If
they are valid then we need to list all blobs and layers that they refer
to and add them to the "keep" list.

Previously the pruning code ignored the manifest list type. Which is a
manifest that lists other manifests. The thought was that this wuold be
fine because the manifests it refers too would also be listed explicitly
and preserved. This would work except that they public facing api using
image names and tags refers to manifests lists and not preserving the
underling data for a manifest list means we cannot lookup the underlying
list of manifests when referring to an image by name resulting in 404
errors.

To fix this we update the pruning process to check which of the two
types of manifest it is dealing with. If it is a manifest list then we
add the blob that contains the manifest list data to the keep list. Then
we iterate through all manifests listed by the manifest list and keep
their blobs as well as their layers. This may not be strictly necessary
as these manifests and layers should be explicitly listed and kept.
Doing it this way ensures that if a newer manifest list refers to an
older manifest that older manifest's backing data will continue to live
as long as that newer manifest list is valid.

A test case is added to ensure that this works as expected.

Change-Id: I66a2e0ad633dcc89290a4a654896edd7baa6750f
2026-02-03 12:12:04 -08:00
2026-02-03 12:12:04 -08:00
2024-01-03 11:00:51 -08:00
2019-09-19 16:08:44 +00:00
2026-01-09 07:06:42 -08:00
2024-01-03 16:32:44 -08:00
2019-09-20 09:53:42 -07:00
2025-12-12 08:52:23 -08:00
2022-12-29 10:49:39 -08:00
2024-01-03 16:32:44 -08:00
2022-12-29 10:49:39 -08:00
2019-10-01 08:09:55 -07:00
2022-12-29 10:49:39 -08:00

Zuul Registry

This is a container image registry for use with the Zuul project gating system.

The defining feature of this registry is support for shadowing images: it allows you to upload a local version of an image to use instead of an upstream version. If you pull an image from this registry, it will provide the local version if it exists, or the upstream if it does not.

This makes it suitable for use in a Zuul-driven speculative image pipeline.

The latest documentation for Zuul is published at: https://zuul-ci.org/docs/

Getting Help

There are two Zuul-related mailing lists:

zuul-announce

A low-traffic announcement-only list to which every Zuul operator or power-user should subscribe.

zuul-discuss

General discussion about Zuul, including questions about how to use it, and future development.

You will also find Zuul developers in the #zuul channel on Freenode IRC.

Contributing

To browse the latest code, see: https://opendev.org/zuul/zuul-registry To clone the latest code, use git clone https://opendev.org/zuul/zuul-registry

Bugs are handled at: https://storyboard.openstack.org/#!/project/zuul/zuul-registry

Suspected security vulnerabilities are most appreciated if first reported privately following any of the supported mechanisms described at https://zuul-ci.org/docs/zuul/user/vulnerabilities.html

Code reviews are handled by gerrit at https://review.opendev.org

After creating a Gerrit account, use git review to submit patches. Example:

# Do your commits
$ git review
# Enter your username if prompted

Join #zuul on Freenode to discuss development or usage.

License

Zuul-registry is free software licensed under the General Public License, version 3.0.

Python Version Support

Zuul requires Python 3. It does not support Python 2.

Description
A speculative container registry
Readme 1.3 MiB
Languages
Python 97.7%
Dockerfile 1.2%
Shell 1.1%