Harbor: Proposal: Tag Retention Policies

Created on 12 Sep 2018  路  7Comments  路  Source: goharbor/harbor

Is your feature request related to a problem? Please describe.

Not many people have the luxury of unlimited storage. For images and tags that are effectively ephemeral (like those built and tagged for use only by an intermediate process in a CI pipeline) it does not make sense to keep these tags around for an extended period of time, consuming precious resources. Other tags, like those correlating to released or deployed software may need to be kept for an extended period of time or even forever for various legal or compliance reasons. While this is possible today via Harbor's API, Harbor Administrators could greatly benefit from having this functionality built-in to harbor itself.

This seems to be a relatively popular issue in the community today:

  • goharbor/harbor#1168 - 寮虹儓寤鸿澧炲姞瀹氭椂鍒犻櫎娓呯悊闀滃儚绛栫暐 (Google Translate: "It is strongly recommended to add a timed delete cleanup mirroring strategy.")
  • goharbor/harbor#4753 - Can not automation clean old images and can not setup clean policy?
  • goharbor/harbor#5085 - Harbor registry tag cleaner tool

Describe the solution you'd like

In general, a chain of "filters" defined at the repository, project, and server level to determine if a tag should be kept or deleted. This filter chain would be run on a collection of tags on some timer process.

The full proposal is available at goharbor/community#4

Additional context

Created from #5420

kinrequirement

Most helpful comment

@nlowe

We're planning to use md file as a proposal content format and use PR raised in goharbor/harbor for reviewing.

Would u please follow the guideline below to move your proposal to there?

git clone https://github.com/goharbor/community git checkout -b YOUR_BRANCH # add md file with meaningful-words_proposal.md name under `proposals/new` folder git commit # raise PR to request merge proposal # reviewers can append comments to the PR

All 7 comments

@nlowe

We're planning to use md file as a proposal content format and use PR raised in goharbor/harbor for reviewing.

Would u please follow the guideline below to move your proposal to there?

git clone https://github.com/goharbor/community git checkout -b YOUR_BRANCH # add md file with meaningful-words_proposal.md name under `proposals/new` folder git commit # raise PR to request merge proposal # reviewers can append comments to the PR

Assign @nlowe as the owner of this proposal.

@steven-zou I'll go ahead and move it today and open a PR. Do you want this issue left open in addition to the PR?

@nlowe

As we're in a transition stage, let's keep it for a while.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

The proposal for this was accepted and merged. I'm hoping to write up a meta issue (and smaller issues for each part) for tracking implementation progress soon. Until then, I'm leaving this open.

Implementation being tracked in #6654

Was this page helpful?
0 / 5 - 0 ratings