KFLUXINFRA-2236: Broaden DR e2e trigger scope - #83385
Conversation
Clone infra-deployments (with PR changes when applicable) and set E2E_BIN_PATH so that mage's ginkgo invocation compiles the DR tests from infra-deployments/tests/disaster-recovery/ instead of e2e-tests. This is the companion change to redhat-appstudio/infra-deployments#12272 which adds the DR test code to infra-deployments. Authored-by: Cursor (Claude) Co-authored-by: Cursor <cursoragent@cursor.com>
Point the DR step script at manish-jangra/infra-deployments K-2236-03 to test the Phase 1 reorder fix (merge PaC config PRs before waiting for pipeline chains) without merging the infra-deployments PR first. TODO: revert to upstream/main once the infra-deployments PR is merged. Assisted-by: Cursor (claude-4.6-opus) Co-authored-by: Cursor <cursoragent@cursor.com>
The backwards-compat DR test requires UPGRADE_BRANCH to perform the Konflux upgrade step. Mirror the logic from the upgrade test step: extract branch/org from the infra-deployments PR when applicable, otherwise default to main/redhat-appstudio. Co-authored-by: Cursor <cursoragent@cursor.com>
performKonfluxUpgrade expects the repo at ./tmp/infra-deployments (relative to CWD) but the script clones to /tmp/infra-deployments. Create a symlink so the upgrade phase can find the clone. Co-authored-by: Cursor <cursoragent@cursor.com>
The symlink approach failed because ginkgo runs the test binary from the package directory, making the relative symlink path unreachable. Export INFRA_DEPLOYMENTS_DIR instead so the Go code can locate the infra-deployments clone directly. Co-authored-by: Cursor <cursoragent@cursor.com>
The repo is cloned from the fork so only origin exists. performKonfluxUpgrade merges remotes/upstream/main, which requires the upstream remote to be configured and fetched. Co-authored-by: Cursor <cursoragent@cursor.com>
The install step pushes a preview branch to the QE fork and configures ArgoCD. The DR test step needs to push merged changes to that same branch. Add the qe remote, fetch it, and query ArgoCD for the target revision so the Go code can push correctly. Co-authored-by: Cursor <cursoragent@cursor.com>
Assisted-by: Claude Code
Assisted-by: Claude Code
Applying fixes to issues found by Coderabbit. Assisted-by: Claude Code
Applying fixes, round I. Assisted-by: Claude Code
Applying fixes, round II. Assisted-by: Claude Code
…ate (iteration 16) Assisted-by: Claude Code
…ppstudio-infra-deployments-main.yaml Co-authored-by: Francesco Ilario <filario@redhat.com>
Assisted-by: Claude Code
# Conflicts: # ci-operator/step-registry/redhat-appstudio/konflux-disaster-recovery/redhat-appstudio-konflux-disaster-recovery-commands.sh
The disaster recovery test validates a full backup/restore/rebuild cycle that exercises 14 components beyond just disaster-recovery itself. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Assisted-by: Claude Code
|
@meyrevived: This pull request references KFLUXINFRA-2236 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the task to target the "5.0.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
@meyrevived, Interacting with pj-rehearseComment: Once you are satisfied with the results of the rehearsals, comment: |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: meyrevived The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/pj-rehearse |
|
@meyrevived: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel. |
|
@meyrevived, |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
WalkthroughThe disaster-recovery test trigger now covers multiple application and infrastructure component directories instead of only ChangesInfrastructure deployment test triggers
Estimated code review effort: 1 (Trivial) | ~2 minutes Mergeability Score: ⚪ Minimal · up to This PR broadens when the disaster-recovery presubmit runs without changing runtime behavior. It is merge-ready after the routine configuration-generation check confirms the source and generated job remain synchronized, with no current merge-blocking risk. Suggested reviewers: 🚥 Pre-merge checks | ✅ 15✅ Passed checks (15 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@meyrevived: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Summary
Widens
run_if_changedfor theappstudio-konflux-disaster-recoverypresubmit so it fires when any component exercised by the DR test changes — not justdisaster-recovery/itself.The DR e2e test runs a full backup → disaster simulation → restore → rebuild cycle. Changes to the following components can break that cycle, but previously did not trigger the test.
Components added to trigger scope
application-apiauthenticationbackupbuild-servicecluster-secret-storeenterprise-contractexternal-secrets-operatorhasimage-controllerintegrationpipeline-serviceproject-controllerreleaseWhat was NOT added (and why)
Components from the initial candidate list that were excluded after cross-referencing DR test code, SOPs, user docs, and infra-deployments structure:
cluster-secret-store-rh— secondary vault store, not exercised by DR testinternal-services— not referenced in test codekonflux-operator— platform dependency but not DR-specific; caught by other testsmonitoring— observability only, test does not validate metrics/alertsnamespace-lister— not referenced anywhere in DR contextrepository-validator— not referenced anywhere in DR contexttrust-manager— not referenced anywhere in DR contextTest plan
/pj-rehearsethe DR presubmit to verify job triggers correctly on component path changesmake jobs🤖 Generated with Claude Code
Summary by CodeRabbit
The
appstudio-konflux-disaster-recoverypresubmit now runs when changes affect any component used by the disaster-recovery end-to-end test, not onlycomponents/disaster-recovery. This expands coverage across application management, authentication, backup and restore, builds, secrets, enterprise contracts, external secrets, image management, integrations, pipelines, project lifecycle, and releases.