Skip to content

Migrate Claude e2e failure analysis to shared claude-ai-helpers step-registry pattern #2407

Description

@kaovilai

Summary

Migrate OADP's e2e failure analysis from the current in-repo Claude CLI setup to the shared claude-ai-helpers step-registry pattern now used by other CI teams (e.g. medik8s, hypershift).

Current approach (this repo)

Added in #2038, present on oadp-dev and oadp-1.6:

  • build/ci-Dockerfile installs Node.js + @anthropic-ai/claude-code (or the claude.ai/install.sh installer on oadp-dev) directly into the test-oadp-operator image.
  • Makefile's test-e2e target invokes tests/e2e/scripts/analyze_failures.sh after Ginkgo exits, wiring GOOGLE_APPLICATION_CREDENTIALS / CLAUDE_CODE_USE_VERTEX / ANTHROPIC_VERTEX_PROJECT_ID from files expected under /var/run/oadp-credentials/gcp-claude-code-*.
  • Those gcp-claude-code-* files were never actually added to the oadp-credentials vault collection / to the openshift/release config, so in practice analyze_failures.sh always hits the "Vertex AI not configured — skipping" branch and no-ops today.

New approach (already used by medik8s, hypershift, security/adversary-scan, etc.)

openshift/release publishes a shared claude-ai-helpers base image (ci namespace, built from openshift-eng/ai-helpers) with Claude Code and CI-analysis skills preinstalled, plus a shared, already-provisioned credential test-credentials/sa-claude-openshift-ci. Consuming repos just add a step-registry post-step to their ci-operator config test — no changes needed inside the repo's own container image or Makefile. See medik8s-analyze-e2e-failure / hypershift-analyze-e2e-failure refs in openshift/release for the pattern.

A companion openshift/release PR adds oadp-analyze-e2e-failure and wires it into the oadp-1.6 and oadp-dev ci-operator configs (the only branches currently carrying the Makefile hook — oadp-1.3/oadp-1.4/oadp-1.5 were checked and don't have it).

Requirements / follow-up changes needed in this repo

Pull Requests

Follow-up (separate scope)

While verifying post-step compatibility across branches, found oadp-1.4's test-e2e target never generates junit_report.xml (missing --ginkgo.junit-report flag, unrelated to the Claude hook — tracked separately in #2410/#2411).

References

Note

Responses generated with Claude

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions