Skip to content

Add GHCR package retention workflow - #124

Merged
atulmgupta merged 1 commit into
mainfrom
chore/package-retention-policy
Sep 19, 2026
Merged

atulmgupta merged 1 commit into
mainfrom
chore/package-retention-policy

Conversation

@atulmgupta

Copy link
Copy Markdown
Contributor

Replace ad hoc image cleanup with a tested retention policy that inventories all published GHCR packages, generates dry-run reports, and supports manual deletion with protected version pins. Document the retention rules and link them from release verification.

Description

Closes #

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would break existing functionality)
  • Documentation update
  • Infrastructure / CI change

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have added tests that prove my fix is effective or my feature works
  • New and existing tests pass locally
  • I have updated the documentation accordingly
  • My changes generate no new warnings

Screenshots (if applicable)

Replace ad hoc image cleanup with a tested retention policy that inventories all published GHCR packages, generates dry-run reports, and supports manual deletion with protected version pins. Document the retention rules and link them from release verification.
Copilot AI lite review requested due to automatic review settings September 19, 2026 18:27
@atulmgupta
atulmgupta merged commit f0fd8b3 into main Sep 19, 2026
34 of 35 checks passed
@atulmgupta
atulmgupta deleted the chore/package-retention-policy branch September 19, 2026 18:28

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Critical workflow and test defects, plus validation and reporting gaps, remain unresolved.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 2 High severity

Open (2)
What changed in this PR

Adds a GHCR package-retention workflow with policy-driven inventory, dry-run reporting, protected versions, controlled deletion, tests, and documentation.

Changes:

  • Implements retention planning, preflight validation, and deletion reporting.
  • Adds package policies and retention tests.
  • Documents retention rules and links them from release verification.
File Description
scripts/​package-retention.test.mjs Tests retention and deletion safety behavior.
scripts/​package-retention.mjs Implements inventory, retention, preflight, and deletion logic.
ops/​release/​package-retention.json Defines packages, retention thresholds, and protected pins.
docs/​operations/​release-verification.md Links release verification to retention documentation.
docs/​operations/​package-retention.md Documents retention policies and safety boundaries.
.github/​workflows/​cleanup.yml Runs scheduled and manual retention operations.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

uses: actions/delete-package-versions@v5
continue-on-error: true
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-node@v4

test('a sparsely published package retains its rollback versions across all packages', () => {
const inventory = fixture();
inventory['teslasync-fleet-telemetry'] = inventory['teslasync-fleet-telemetry'].slice(0, 2);

Copilot AI commented Sep 19, 2026

Copy link
Copy Markdown

One or more custom setup steps configured for this repository failed during this Copilot code review run:

Verify TypeScript build

Setup steps run before each review. If the review above is missing context, or no review was posted at all, the failing step above may be the cause. See the workflow run for failure details, fix your setup steps configuration, and re-request a review.

Note

You can configure setup steps for Copilot code review separately from Copilot cloud agent with a copilot-code-review.yml file. Read the docs for details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants