Skip to content

chore(mgmt): remove obsolete PKO cleanup tooling (AROSLSRE-1197)#5693

Open
raelga wants to merge 1 commit into
Azure:mainfrom
raelga:aroslsre-pko-cleanup-removal
Open

chore(mgmt): remove obsolete PKO cleanup tooling (AROSLSRE-1197)#5693
raelga wants to merge 1 commit into
Azure:mainfrom
raelga:aroslsre-pko-cleanup-removal

Conversation

@raelga

@raelga raelga commented Jun 17, 2026

Copy link
Copy Markdown
Collaborator

AROSLSRE-1197

What

Removes the obsolete one-time PKO (Package Operator) cleanup tooling from the management cluster rollout:

  • Drops the cleanup-pko EV2 Shell step (and its TODO) from dev-infrastructure/mgmt-pipeline.yaml.
  • Drops the cleanup-pko build block from the pipeline buildStep (the recreate-system-pool / recreate-broken-pools builds are untouched).
  • Deletes the dev-infrastructure/scripts/cleanup-pko-resources/ Go module.
  • Removes its go.work entry and the .gitignore binary entry.

Why

The cleanup-pko step and its Go helper were a one-time migration to remove orphaned PKO resources that blocked cluster deletion on MGMT clusters (epic AROSLSRE-782). #5366 hardened it to run as a built Go binary. The step itself carried a TODO: Remove this PKO cleanup step once all management clusters have been cleaned up ([ARO-23308](https://redhat.atlassian.net/browse/ARO-23308)).

Now that the rollout has completed across all management clusters, the step runs on every mgmt rollout as dead code. This removes it.

Testing

  • make validate-changed-config-pipelines passes.
  • go work sync clean; no module references the deleted path.
  • grep -r cleanup-pko returns no matches after the change.

Special notes for your reviewer

Warning

/hold — do not merge until we have validation that the PKO cleanup has actually completed on all management clusters (int/stage/prod). Removing the step early would strand orphaned PKO resources on any cluster that has not yet been swept. Lift the hold once that is confirmed.

The unrelated package-operator library dependency used by tooling/olm-bundle-repkg is intentionally untouched.

PR Checklist

  • PR is scoped to a single task (no mixed concerns)
  • Title follows Conventional Commits format
  • Summary explains the "Why" behind the change
  • Linked to relevant ticket/issue
  • Screenshots included (if graph/UI/metrics changes)
  • Self-reviewed the diff
  • CI/CD checks are passing (ignore Tide)
  • Draft PR used for WIP (if applicable)
  • Commit history is clean (rebased/squashed)
  • Tricky code blocks are commented
  • Specific reviewers tagged
  • All comment threads resolved before merge

The cleanup-pko EV2 Shell step and its Go helper were a one-time
migration to remove orphaned Package Operator resources blocking
cluster deletion (PR Azure#5366 hardened it to a built binary). Now that
the rollout has completed across all management clusters, remove the
dead code:

- Drop the cleanup-pko Shell step and its build block from
  dev-infrastructure/mgmt-pipeline.yaml
- Delete the dev-infrastructure/scripts/cleanup-pko-resources module
- Remove its go.work and .gitignore entries

recreate-system-pool and recreate-broken-pools tooling is untouched.
Copilot AI review requested due to automatic review settings June 17, 2026 11:02
@openshift-ci

openshift-ci Bot commented Jun 17, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: raelga

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot requested review from mmazur and roivaz June 17, 2026 11:03
@raelga

raelga commented Jun 17, 2026

Copy link
Copy Markdown
Collaborator Author

/hold

Holding until we have validation that the PKO cleanup has completed on all management clusters (int/stage/prod). Removing the rollout step before that is confirmed would strand orphaned PKO resources on any cluster not yet swept. /hold cancel once confirmed.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Removes the now-obsolete “cleanup-pko” management cluster rollout step and its associated one-off Go tooling, reducing dead code in the mgmt EV2 pipeline and workspace module list.

Changes:

  • Removed the cleanup-pko EV2 Shell step and its build output generation from dev-infrastructure/mgmt-pipeline.yaml.
  • Deleted the dev-infrastructure/scripts/cleanup-pko-resources/ Go module (code + tests + go.mod/go.sum).
  • Removed related workspace and ignore-list entries (go.work, dev-infrastructure/.gitignore).

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
go.work Removes the deleted PKO cleanup module from the Go workspace.
dev-infrastructure/mgmt-pipeline.yaml Drops the PKO cleanup binary build and the rollout step that executed it.
dev-infrastructure/.gitignore Removes the ignored PKO cleanup binary path since it no longer exists.
dev-infrastructure/scripts/cleanup-pko-resources/main.go Deletes the obsolete PKO cleanup implementation.
dev-infrastructure/scripts/cleanup-pko-resources/main_test.go Deletes tests for the removed PKO cleanup tool.
dev-infrastructure/scripts/cleanup-pko-resources/go.mod Deletes the standalone module definition for the removed tool.
dev-infrastructure/scripts/cleanup-pko-resources/go.sum Deletes dependency checksums for the removed module.

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