Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Minor
-
Resolution: Won't Do
-
Affects Version/s: 3.4.0
-
Fix Version/s: None
-
Component/s: Docker
-
Labels:
-
Environment:(MacOSX)
-
Story Points:2
Description
When I have 2 images with different tags but delete one using curl, it removes the sha file and the latest image but leaves the other image there. This was intentional after NEXUS-12711 but further work could be done so delete both images.
The workaround is run the delete again and it will remove the second image.
Steps to repro:
1) docker pull hello-world
2) docker tag hello-world <hosted:port>/hello-world
3) docker push <hosted:port>/hello-world
4) docker tag hello-world <hosted:port>/hello-world:second
5) docker push <hosted:port>/hello-world:second
6) curl -v -u 'admin:admin123' -H 'Accept:application/vnd.docker.distribution.manifest.v2+json' https://<hosted:port>/v2/hello-world/manifests/latest -k
7) curl -v -X DELETE -u 'admin:admin123' https://<hosted:port>/v2/hello-world/manifests/sha256:<Docker-Content-Digest> -k
8) curl -u 'admin:admin123' https://<hosted:port>/v2/hello-world/tags/list -k
shows "second". UI also shows image and manifest for second.
WEIRD9) curl -v -u 'admin:admin123' -H 'Accept:application/vnd.docker.distribution.manifest.v2+json' https://<hosted:port>/v2/hello-world/manifests/second -k
shows the <Docker-Content-Digest> same as latest. So seems an associated file is now missing (on push, both the manifest and sha file are created).
Attachments
Issue Links
- discovered while testing
-
NEXUS-12711 Nexus docker registry delete REST api partially deletes an image
-
- Closed
-
- relates
-
NEXUS-14838 Random version deleted if there are multiple versions with same digest
-
- Closed
-