Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ if oc get packagemanifest -l "catalog=${ODF_SUBSCRIPTION_SOURCE}" -n openshift-m
-o jsonpath='{.items[?(@.metadata.name=="odf-operator")].status.channels[*].name}' | tr ' ' '\n' | sort -V | tail -1)
else
echo "odf-operator package not found in ${ODF_SUBSCRIPTION_SOURCE} catalog, creating ODF 4.23 catalog source with ICSP"
sleep 6h

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.

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Find workflow timeout settings and all callers of the ODF installation step.
rg -n -C 6 \
  'hypershift-kubevirt-install-odf|active_deadline_seconds|timeout:|timeout=' \
  --glob '*.yaml' --glob '*.yml' .

Repository: openshift/release

Length of output: 50374


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Inspect the step definition, command script, and exact workflow references.
printf '%s\n' '--- step files ---'
fd -i 'hypershift-kubevirt-install-odf' ci-operator/step-registry | sort

printf '%s\n' '--- command script ---'
cmd='ci-operator/step-registry/hypershift/kubevirt/install/odf/hypershift-kubevirt-install-odf-commands.sh'
cat -n "$cmd"

printf '%s\n' '--- exact references ---'
rg -n -C 12 --glob '*.yaml' --glob '*.yml' \
  'hypershift-kubevirt-install-odf' \
  ci-operator/config ci-operator/jobs ci-operator/step-registry

Repository: openshift/release

Length of output: 50373


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- step files ---'
fd -i 'hypershift-kubevirt-install-odf' ci-operator/step-registry | sort

printf '%s\n' '--- command script ---'
cmd='ci-operator/step-registry/hypershift/kubevirt/install/odf/hypershift-kubevirt-install-odf-commands.sh'
cat -n "$cmd"

printf '%s\n' '--- exact references ---'
rg -n -C 12 --glob '*.yaml' --glob '*.yml' \
  'hypershift-kubevirt-install-odf' \
  ci-operator/config ci-operator/jobs ci-operator/step-registry

Repository: openshift/release

Length of output: 50373


🏁 Script executed:

#!/bin/bash
set -euo pipefail

step='ci-operator/step-registry/hypershift/kubevirt/install/odf/hypershift-kubevirt-install-odf-ref.yaml'
printf '%s\n' '--- step definition ---'
cat -n "$step"

printf '%s\n' '--- workflow timeout and ordering ---'
for f in \
  ci-operator/step-registry/hypershift/kubevirt/e2e-aws/hypershift-kubevirt-e2e-aws-workflow.yaml \
  ci-operator/step-registry/hypershift/kubevirt/e2e-aws/capk/hypershift-kubevirt-e2e-aws-capk-workflow.yaml \
  ci-operator/step-registry/hypershift/mce/kubevirt/conformance/hypershift-mce-kubevirt-conformance-workflow.yaml \
  ci-operator/step-registry/hypershift/mce/kubevirt/azure/conformance/hypershift-mce-kubevirt-azure-conformance-workflow.yaml \
  ci-operator/step-registry/hypershift/mce/ibmz/conformance-s390xmgmt-kubevirt/hypershift-mce-ibmz-conformance-s390xmgmt-kubevirt-workflow.yaml \
  ci-operator/step-registry/hypershift/mce/ibmz/openshift-e2e-test-s390xmgmt-kubevirt/hypershift-mce-ibmz-openshift-e2e-test-s390xmgmt-kubevirt-workflow.yaml
do
  if [[ -f "$f" ]]; then
    echo "--- $f ---"
    cat -n "$f" | sed -n '1,45p'
  fi
done

printf '%s\n' '--- direct periodics using the step ---'
rg -l --glob '*.yaml' --glob '*.yml' \
  'ref: hypershift-kubevirt-install-odf' \
  ci-operator/config ci-operator/jobs |
  sort |
  while read -r f; do
    echo "--- $f ---"
    rg -n -C 8 'ref: hypershift-kubevirt-install-odf|timeout:' "$f"
  done

Repository: openshift/release

Length of output: 20790


Replace the six-hour sleep with bounded polling.

This step runs before HyperShift installation and e2e tests. The sleep 6h can consume the workflow timeout. The script does not recheck odf-operator after sleeping, so a package that appears during the delay still triggers the ODF 4.23 fallback. Poll for package availability and create fallback resources only when the package remains unavailable.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@ci-operator/step-registry/hypershift/kubevirt/install/odf/hypershift-kubevirt-install-odf-commands.sh`
at line 28, Replace the fixed `sleep 6h` in the HyperShift KubeVirt ODF install
flow with bounded polling that repeatedly checks `odf-operator` package
availability. Proceed as soon as the package appears; only after the polling
limit is reached should the script create the ODF 4.23 fallback resources.


# Create ImageContentSourcePolicy for ODF 4.23
echo "Creating ImageContentSourcePolicy for ODF repositories"
Expand Down