Skip to main content

Retention rule

A Retention Rule defines criteria that automatically retain or delete images and tags in a Repository, so storage stays optimized without manual cleanup.

Overview​

  • Matching: a rule scopes to specific Repositories and Tags by exact name, comma-separated list, or wildcard — or to all of them.
  • Criteria: a rule retains images by count (most recently pushed or pulled) or by age (days since pushed or pulled).
  • Schedule: a rule can run on demand (RUN NOW or DRY RUN) or automatically on a recurring schedule — one schedule applies to every rule.
  • Lifecycle: a rule can be disabled, re-enabled, or deleted. See Manage retention rules & runs before you delete one.

See also​