Support deleting an image tag

If the Docker Registry API allows for images to be deleted, issuing the
command `delete <image> <tag>` will result in the tag being removed from
the server.

A limitation of this change is that it will cause any unreferenced tags
to become orphaned, requiring the garbage collector within the docker
registry server to clean these up.  This is because there is no way to
efficiently determine if each of the layers are reused by other tags or
images on the server.

Implement delete logic

Fix broken unit tests
This commit is contained in:
Anthony Oteri
2023-09-29 17:18:04 -04:00
parent 48070cff1f
commit fbe43f03f1
5 changed files with 128 additions and 15 deletions
+2 -1
View File
@@ -37,4 +37,5 @@ url = { version = "2.4.1", features = ["serde"] }
xdg = "2.5.2"
[dev-dependencies]
mockito = "1.2.0"
mockito = "1.2.0"
env_logger = "0.10.0"