Skip to content

Acr Purge --unttaged is targetting tagged manifests? #480

@DarylGraves

Description

@DarylGraves

Describe the bug
When I run acr purge --filter <target> --ago 1d --untagged --dry-run --registry <myRegistry> it's saying it will delete manifests which are tagged?

To Reproduce
Steps to reproduce the behavior:

  1. Have a container repository with at least 1x Tag and Multiple Manifests underneath.
  2. In PowerShell, add these two variables: $registry = "YourRegHere" and $repo = "YourRepoHere"
  3. Run az acr repository show-manifests --name $registry --repository $repo --output json | ConvertFrom-Json | Select-Object digest, tags
  4. Review the output - In my case there is one tagged manifest and 30+ without tags.
  5. Run acr purge --filter $repo --ago 1d --untagged -dry-run --registry $registry
  6. Review the output - Note how the hash is in the dry run to be deleted!

Expected behavior
The name says --untagged so I expect it to only remove untagged manifests...

Screenshots
List of all manifests:
Image
List of manifests being deleted (note how the tagged one is in there)
Image

Any relevant environment information

  • OS: Windows
  • Version: 0.16, Revision: 2913fa4

Additional context
Also curious to know why these commands aren't part of the usual az suite? Seems a bit weird that it's a completely different executable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions