-
Notifications
You must be signed in to change notification settings - Fork 218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deleting using 'tags-like' keeps digest, not removing tag #89
Comments
Why do you expect that orphan digests will be created after build?
From your command I can see that you are passing --num 0 which means that
no tags will be deleted.
Please try putting some non-zero number here.
…On Thu, Mar 19, 2020 at 12:30 AM PBX_g33k ***@***.***> wrote:
We're trying to use this tool to keep our internal registry clean using
our CI/CD infrastructure, but i seem to be unable to delete tags from our
registry.
Our CI build images and pushes these to the registry, upon build only one
tag is used based on the branch name, so we can exclude that digest are
referenced by multiple tags.
I would expect the tool to delete the unused/untagged digest since it's
not refered by any other tag than the one we have pushed from CI.
% docker run --rm anoxis/registry-cli -r $REGISTRY_URL --delete --num 0 --tags-like "feature-tag" "feature-tag-frontend"
Will delete all but 0 last tags
---------------------------------
Image: some-product
tag like: feature-tag
Adding feature-tag to tags list
tag like: feature-tag-frontend
tag: feature-tag
Getting digests for tags to keep:
Getting digest for tag feature-tag
Keep digest sha256:474edf4ac40cd07c1bb225dd9cb4c75b9272b8b7fe2994233e3e1e57ee0e7c91 for tag feature-tag
---------------------------------
Image: some-product-frontend
tag like: feature-tag
Adding feature-tag to tags list
tag like: feature-tag-frontend
tag: feature-tag
Getting digests for tags to keep:
Getting digest for tag feature-tag
Keep digest sha256:bc01bede6ca516d98eb26914a3a8f5ea40c86029eb863a9d70bd4b9888793f00 for tag feature-tag
Am i executing the script incorrectly or is this a bug?
Registry is running on the registry:2.7.1 image.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#89>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AECNB63Q6KL5DNCY7GLSU4DRIEHNRANCNFSM4LOX4CFQ>
.
|
I'm not expecting orphaned digest to be created, i just wanted to doublecheck and explicitly mentioned that the created layers are only referenced by a single tag, and removing that that would render them orphaned. Running the same command without |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We're trying to use this tool to keep our internal registry clean using our CI/CD infrastructure, but i seem to be unable to delete tags from our registry.
Our CI build images and pushes these to the registry, upon build only one tag is used based on the branch name, so we can exclude that digest are referenced by multiple tags.
I would expect the tool to delete the unused/untagged digest since it's not refered by any other tag than the one we have pushed from CI.
Am i executing the script incorrectly or is this a bug?
Registry is running on the
registry:2.7.1
image.The text was updated successfully, but these errors were encountered: