Skip to content

Fix connected OVE job#79903

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift:mainfrom
mhanss:fix-ove-con
Jun 1, 2026
Merged

Fix connected OVE job#79903
openshift-merge-bot[bot] merged 1 commit into
openshift:mainfrom
mhanss:fix-ove-con

Conversation

@mhanss
Copy link
Copy Markdown
Contributor

@mhanss mhanss commented Jun 1, 2026

Summary by CodeRabbit

This PR updates OpenShift CI configuration and ci-operator step scripts to fix a failing connected OVE (Open Virtualization Environment) baremetal job by making proxy handling conditional on whether the run is disconnected.

What changed (practical impact)

  • Scope: CI configuration and ci-operator step-registry for agent-qe baremetal OVE install flows and a baremetal preflight step in the OpenShift CI repo. These changes prevent connected runs from failing due to missing proxy files that only exist in disconnected environments.
  • Proxy handling: Install scripts for both the normal and disconnected OVE flows now check DISCONNECTED and only validate/source ${SHARED_DIR}/proxy-conf.sh when DISCONNECTED == "true". In connected mode the script no longer fails if proxy-conf.sh is absent.
  • Environment flags: Step-ref YAMLs for the agent-qe OVE install steps (base and disconnected variants) add a DISCONNECTED env with default "false".
  • Preflight proxy propagation: The baremetal lab pre-serial-console step now reads proxy from ${CLUSTER_PROFILE_DIR}/proxy and exports HTTP_PROXY/HTTPS_PROXY accordingly, removing the prior unconditional sourcing of proxy-conf.sh.
  • Job config: The baremetal-ove-compact-konflux test job now references a specific OVE UI ISO snapshot image and the job is configured to run with DISCONNECTED: "false" by default.

Concrete edits

  • ci-operator/step-registry/agent-qe/baremetal/install/ove/*: scripts updated to only require/source proxy-conf.sh when DISCONNECTED == "true".
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/*-ref.yaml and disconnected variants: added env.DISCONNECTED.default = "false".
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh: now reads cluster profile proxy and exports HTTP_PROXY/HTTPS_PROXY.
  • ci-operator/config/openshift-eng/agent-qe-infra/...release-4.21__amd64-nightly.yaml: baremetal-ove-compact-konflux job updated to use a specific OVE UI ISO snapshot and DISCONNECTED: "false".

Why this fixes the problem

  • Previously scripts unconditionally required and sourced ${SHARED_DIR}/proxy-conf.sh (which exists only in disconnected jobs), causing connected OVE jobs to fail when that file was missing. Making proxy sourcing conditional and defaulting DISCONNECTED to "false" allows connected runs to proceed while preserving disconnected behavior.

Notes for reviewers

  • Changes are confined to CI job definitions and step scripts; no public API changes.
  • Total changes are small: script edits (medium review effort) and YAML updates (low review effort).

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jun 1, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

Gate sourcing of proxy-conf.sh on a new DISCONNECTED env flag for OVE install steps, refactor serial-console proxy exports to read from cluster profile, and pin the OVE UI ISO snapshot for the baremetal-ove-compact-konflux job.

Changes

OVE Baremetal Installation and Testing Infrastructure

Layer / File(s) Summary
OVE install steps: Conditional proxy configuration
ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh, ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml, ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh, ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml, ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh, ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
Add DISCONNECTED env var (default "false") to step refs and conditionalize existence-checking and sourcing of ${SHARED_DIR}/proxy-conf.sh so it only runs when DISCONNECTED == "true".
Serial console proxy configuration refactor
ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh
Stop conditional sourcing of ${SHARED_DIR}/proxy-conf.sh; read proxy from ${CLUSTER_PROFILE_DIR}/proxy and export HTTP_PROXY and HTTPS_PROXY.
Test job snapshot configuration
ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
Pin baremetal-ove-compact-konflux job env.SNAPSHOT to a specific OVE UI ISO image reference.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • openshift/release#79826: Both PRs modify OVE-related job environment variables and relate to gating proxy use via DISCONNECTED.

Suggested labels

lgtm, rehearsals-ack

Suggested reviewers

  • pamoedom
  • bmanzari

Important

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

❌ Failed checks (1 error, 1 inconclusive)

Check name Status Explanation Resolution
No-Sensitive-Data-In-Logs ❌ Error Scripts expose sensitive credentials: BMC passwords passed in curl -u flag and IPMITOOL_PASSWORD exported to environment variables, visible in process listings and logs. Redact credentials from curl commands. Don't export passwords as environment variables. Use credential files or secret masking in CI logs.
Title check ❓ Inconclusive The title 'Fix connected OVE job' is vague and does not clearly convey what specific issue is being fixed or what changes are being made in the pull request. Provide a more specific title that describes the actual fix, such as 'Make proxy configuration conditional in disconnected mode' or 'Fix OVE job proxy configuration handling'.
✅ Passed checks (13 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed PR modifies only shell scripts and YAML config files in CI operator step registry. No Ginkgo test files with It(), Describe(), or Context() patterns are present.
Test Structure And Quality ✅ Passed This PR modifies shell scripts and YAML configuration files only (no Go/Ginkgo test code). The custom check for Ginkgo test structure and quality is not applicable to this PR.
Microshift Test Compatibility ✅ Passed No new Ginkgo e2e tests are added in this PR; all changes are to CI/CD scripts and configuration (shell scripts and YAML files), so the MicroShift test compatibility check is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed This PR contains no Ginkgo e2e tests—only CI/CD infrastructure shell scripts and YAML configs. The SNO compatibility check applies only to new Ginkgo tests.
Topology-Aware Scheduling Compatibility ✅ Passed PR changes are CI/CD pipeline configurations and test automation scripts with no deployment manifests, operator code, or scheduling constraints that could affect cluster topologies.
Ote Binary Stdout Contract ✅ Passed OTE Binary Stdout Contract check not applicable: PR modifies only shell scripts and YAML CI configs, no Go source code or OTE binary implementation present.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed No new Ginkgo e2e tests are added in this PR. The changes are CI infrastructure modifications (shell scripts and YAML configurations) only, not test code.
No-Weak-Crypto ✅ Passed No weak cryptographic algorithms (MD5, SHA1, DES, RC4, 3DES, Blowfish, ECB), custom crypto implementations, or non-constant-time secret comparisons found in the PR changes.
Container-Privileges ✅ Passed No container privilege escalation settings found. PR modifies CI-Operator configs only, not Kubernetes pod specs.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci openshift-ci Bot requested review from bmanzari and pamoedom June 1, 2026 07:40
@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 1, 2026
@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with 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.

Inline comments:
In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`:
- Around line 13-19: The if-test directly expands DISCONNECTED and will
hard-fail under set -o nounset; update the conditional in
agent-qe-baremetal-install-ove-commands.sh to use a defaulted expansion for the
DISCONNECTED variable (use the ${DISCONNECTED:-...} form) so the test does not
error when the variable is unset, leaving the rest of the block (checking
SHARED_DIR/proxy-conf.sh and sourcing it) unchanged.

In
`@ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh`:
- Around line 3-6: The script currently overwrites NO_PROXY with only
"localhost,127.0.0.1" which causes Redfish/BMC curl calls to go through the
proxy; instead, read the proxy into HTTP_PROXY/HTTPS_PROXY as you already do,
then build NO_PROXY by starting from any existing NO_PROXY value and appending
"localhost,127.0.0.1" plus the BMC hostnames/IPs parsed from
${SHARED_DIR}/hosts.yaml (extract the host entries used by the curl calls) and
export that combined NO_PROXY before the curl calls; update the NO_PROXY
assignment in baremetal-lab-pre-serial-console-commands.sh to preserve existing
NO_PROXY (e.g.,
NO_PROXY="${NO_PROXY:+$NO_PROXY,}localhost,127.0.0.1,${BMC_LIST}") where
BMC_LIST is populated by parsing ${SHARED_DIR}/hosts.yaml, then ensure the curl
commands (the ones using https://$bmc_address) run with this updated NO_PROXY.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Enterprise

Run ID: 14741f88-00fa-40fb-ad74-318685af0f85

📥 Commits

Reviewing files that changed from the base of the PR and between 13451be and f283b44.

📒 Files selected for processing (8)
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh
✅ Files skipped from review due to trivial changes (1)
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
🚧 Files skipped from review as they are similar to previous changes (3)
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml

Comment on lines +13 to +19
if [ "${DISCONNECTED}" == "true" ]; then
[ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
echo "Proxy conf file is not found. Failing."
exit 1
}
source "${SHARED_DIR}/proxy-conf.sh"
fi
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.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

FILE="ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh"

if [ ! -f "$FILE" ]; then
  echo "MISSING: $FILE"
  exit 1
fi

echo "---- Relevant lines ($FILE) ----"
nl -ba "$FILE" | sed -n '1,80p'
echo "---- grep DISCONNECTED occurrences ----"
rg -n "DISCONNECTED" "$FILE" || true

Repository: openshift/release

Length of output: 250


🏁 Script executed:

#!/bin/bash
set -euo pipefail

FILE="ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh"

if [ ! -f "$FILE" ]; then
  echo "MISSING: $FILE"
  exit 1
fi

echo "---- First 120 lines ($FILE) ----"
awk 'NR<=120 { printf "%5d\t%s\n", NR, $0 }' "$FILE"

echo "---- DISCONNECTED occurrences ($FILE) ----"
grep -n "DISCONNECTED" "$FILE" || true

Repository: openshift/release

Length of output: 3301


Guard DISCONNECTED against nounset hard-fail.

ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh enables set -o nounset and expands ${DISCONNECTED} directly in if [ "${DISCONNECTED}" == "true" ]; then, which fails when DISCONNECTED is unset. Use a defaulted expansion.

Suggested patch
-if [ "${DISCONNECTED}" == "true" ]; then
+if [ "${DISCONNECTED:-false}" == "true" ]; then
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
if [ "${DISCONNECTED}" == "true" ]; then
[ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
echo "Proxy conf file is not found. Failing."
exit 1
}
source "${SHARED_DIR}/proxy-conf.sh"
fi
if [ "${DISCONNECTED:-false}" == "true" ]; then
[ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
echo "Proxy conf file is not found. Failing."
exit 1
}
source "${SHARED_DIR}/proxy-conf.sh"
fi
🧰 Tools
🪛 Shellcheck (0.11.0)

[info] 18-18: Not following: ./proxy-conf.sh was not specified as input (see shellcheck -x).

(SC1091)

🤖 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/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`
around lines 13 - 19, The if-test directly expands DISCONNECTED and will
hard-fail under set -o nounset; update the conditional in
agent-qe-baremetal-install-ove-commands.sh to use a defaulted expansion for the
DISCONNECTED variable (use the ${DISCONNECTED:-...} form) so the test does not
error when the variable is unset, leaving the rest of the block (checking
SHARED_DIR/proxy-conf.sh and sourcing it) unchanged.

Comment on lines +3 to +6
proxy="$(<"${CLUSTER_PROFILE_DIR}/proxy")"
export HTTP_PROXY=${proxy}
export HTTPS_PROXY=${proxy}
export NO_PROXY="localhost,127.0.0.1"
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.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Locate and print the relevant script with line numbers
target="ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh"
echo "=== File: $target ==="
nl -ba "$target" | sed -n '1,140p'

# Check for other proxy/no_proxy handling in the step registry (nearby steps too)
echo "=== rg: NO_PROXY / HTTP_PROXY / HTTPS_PROXY usage in step-registry ==="
rg -n --hidden --no-ignore-vcs 'NO_PROXY|HTTP_PROXY|HTTPS_PROXY|curl .*https://\$bmc_address|bmc_address|redfish' ci-operator/step-registry/baremetal/lab/pre/serial-console -S || true

echo "=== rg: hosts.yaml / bmc_address parsing references ==="
rg -n --hidden --no-ignore-vcs 'hosts\.yaml|bmc_address|CLUSTER_PROFILE_DIR|SHARED_DIR' ci-operator/step-registry/baremetal/lab -S || true

# Show any hosts.yaml template/example if present (to validate suggested patch assumptions)
echo "=== Find hosts.yaml occurrences/files ==="
fd -a 'hosts\.yaml' ci-operator/step-registry/baremetal/lab || true

Repository: openshift/release

Length of output: 240


🏁 Script executed:

#!/bin/bash
set -euo pipefail

target="ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh"

echo "=== Check file exists ==="
ls -la "$target" || true

echo "=== Show file (line-numbered via cat -n) ==="
if [ -f "$target" ]; then
  cat -n "$target" | sed -n '1,160p'
fi

echo "=== rg: Proxy/NO_PROXY usage in relevant directory ==="
rg -n --hidden --no-ignore-vcs 'NO_PROXY|HTTP_PROXY|HTTPS_PROXY' "ci-operator/step-registry/baremetal/lab/pre/serial-console" -S || true

echo "=== rg: Redfish/BMC curl usage and bmc_address references in relevant directory ==="
rg -n --hidden --no-ignore-vcs 'curl .*https://\$bmc_address|bmc_address|redfish' "ci-operator/step-registry/baremetal/lab/pre/serial-console" -S || true

echo "=== rg: Any hosts.yaml parsing in this step subtree ==="
rg -n --hidden --no-ignore-vcs 'hosts\.yaml|\.bmc_address|bmc_address' "ci-operator/step-registry/baremetal/lab" -S || true

echo "=== Find any step-registry command scripts containing `export NO_PROXY=` globally ==="
rg -n --hidden --no-ignore-vcs 'export NO_PROXY=' ci-operator/step-registry -S || true

Repository: openshift/release

Length of output: 25659


Fix NO_PROXY handling for Redfish/BMC requests
baremetal-lab-pre-serial-console-commands.sh sets HTTP_PROXY/HTTPS_PROXY from CLUSTER_PROFILE_DIR/proxy but overwrites NO_PROXY to only localhost,127.0.0.1 (line 6). The script then runs curl -k ... https://$bmc_address/... for Redfish/iDRAC (lines 22, 23, 29, 35, 41), which can be routed through the proxy and break lab serial-console setup.

Update NO_PROXY to preserve existing entries and include the BMC hostnames from ${SHARED_DIR}/hosts.yaml (instead of replacing it with localhost-only).

🤖 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/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh`
around lines 3 - 6, The script currently overwrites NO_PROXY with only
"localhost,127.0.0.1" which causes Redfish/BMC curl calls to go through the
proxy; instead, read the proxy into HTTP_PROXY/HTTPS_PROXY as you already do,
then build NO_PROXY by starting from any existing NO_PROXY value and appending
"localhost,127.0.0.1" plus the BMC hostnames/IPs parsed from
${SHARED_DIR}/hosts.yaml (extract the host entries used by the curl calls) and
export that combined NO_PROXY before the curl calls; update the NO_PROXY
assignment in baremetal-lab-pre-serial-console-commands.sh to preserve existing
NO_PROXY (e.g.,
NO_PROXY="${NO_PROXY:+$NO_PROXY,}localhost,127.0.0.1,${BMC_LIST}") where
BMC_LIST is populated by parsing ${SHARED_DIR}/hosts.yaml, then ensure the curl
commands (the ones using https://$bmc_address) run with this updated NO_PROXY.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

♻️ Duplicate comments (1)
ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh (1)

13-13: ⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Guard DISCONNECTED against nounset hard-fail.

With set -o nounset enabled, the expansion ${DISCONNECTED} will fail if the variable is unset. Use a defaulted expansion to prevent script failure.

🛡️ Proposed fix
-if [ "${DISCONNECTED}" == "true" ]; then
+if [ "${DISCONNECTED:-false}" == "true" ]; then
🤖 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/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`
at line 13, The if-test using ${DISCONNECTED} can hard-fail under set -o
nounset; update the conditional in agent-qe-baremetal-install-ove-commands.sh to
use a defaulted expansion (e.g. ${DISCONNECTED:-false} or ${DISCONNECTED:-}) so
the test safely handles an unset variable, replacing the current line that reads
if [ "${DISCONNECTED}" == "true" ]; then with a defaulted form that compares the
safe expansion to "true".
🤖 Prompt for all review comments with 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.

Inline comments:
In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh`:
- Line 22: The conditional using ${DISCONNECTED} will hard-fail under set -o
nounset; update the if check that references DISCONNECTED to use a defaulted
expansion (e.g. use ${DISCONNECTED:-false} or ${DISCONNECTED:-} in the
conditional) so the test does not error when DISCONNECTED is unset; locate the
conditional line that reads if [ "${DISCONNECTED}" == "true" ]; then and replace
the bare expansion with a defaulted one to safely handle unset variables.

In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh`:
- Line 13: The guard using ${DISCONNECTED} can hard-fail under set -o nounset;
update the conditional to use a defaulted expansion (e.g., ${DISCONNECTED:-}) so
the test doesn't throw when DISCONNECTED is unset—locate the if test that
references DISCONNECTED (the line starting with if [ "${DISCONNECTED}" == "true"
]; then) and replace the unguarded expansion with a defaulted form like
${DISCONNECTED:-false} or ${DISCONNECTED:-} to safely evaluate the condition.

---

Duplicate comments:
In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`:
- Line 13: The if-test using ${DISCONNECTED} can hard-fail under set -o nounset;
update the conditional in agent-qe-baremetal-install-ove-commands.sh to use a
defaulted expansion (e.g. ${DISCONNECTED:-false} or ${DISCONNECTED:-}) so the
test safely handles an unset variable, replacing the current line that reads if
[ "${DISCONNECTED}" == "true" ]; then with a defaulted form that compares the
safe expansion to "true".
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Enterprise

Run ID: 6e6160b3-b35b-40c2-8bb0-97fbd17e44d4

📥 Commits

Reviewing files that changed from the base of the PR and between f283b44 and d8c1ba9.

📒 Files selected for processing (8)
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh
✅ Files skipped from review due to trivial changes (3)
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
🚧 Files skipped from review as they are similar to previous changes (2)
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

♻️ Duplicate comments (3)
ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh (1)

13-19: ⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Guard DISCONNECTED for nounset safety.

With set -o nounset (Line 6), ${DISCONNECTED} can hard-fail when unset. Use a defaulted expansion.

Suggested patch
-if [ "${DISCONNECTED}" == "true" ]; then
+if [ "${DISCONNECTED:-false}" == "true" ]; then
   [ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
     echo "Proxy conf file is not found. Failing."
     exit 1
   }
   source "${SHARED_DIR}/proxy-conf.sh"
 fi
#!/bin/bash
set -euo pipefail

FILE="ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh"
nl -ba "$FILE" | sed -n '1,30p'
echo "--- nounset + unguarded DISCONNECTED check ---"
rg -n 'set -o nounset|"\$\{DISCONNECTED\}"' "$FILE"
🤖 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/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`
around lines 13 - 19, The check if [ "${DISCONNECTED}" == "true" ] can fail
under set -o nounset when DISCONNECTED is unset; change the condition to use a
defaulted expansion like ${DISCONNECTED:-} (i.e., reference DISCONNECTED with a
fallback) so the shell won't error on nounset. Update the conditional that
references DISCONNECTED in the installation script (the if block that sources
proxy-conf.sh and checks SHARED_DIR/proxy-conf.sh) to use the defaulted
expansion and keep the rest of the logic unchanged.
ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh (1)

22-28: ⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Use defaulted expansion for DISCONNECTED.

set -o nounset makes ${DISCONNECTED} unsafe if unset; guard it with a default.

Suggested patch
-if [ "${DISCONNECTED}" == "true" ]; then
+if [ "${DISCONNECTED:-false}" == "true" ]; then
   [ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
     echo "Proxy conf file is not found. Failing."
     exit 1
   }
   source "${SHARED_DIR}/proxy-conf.sh"
 fi
#!/bin/bash
set -euo pipefail

FILE="ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh"
nl -ba "$FILE" | sed -n '1,40p'
echo "--- nounset + unguarded DISCONNECTED check ---"
rg -n 'set -o nounset|"\$\{DISCONNECTED\}"' "$FILE"
🤖 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/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh`
around lines 22 - 28, The check against DISCONNECTED is unsafe under set -o
nounset; update the conditional to use defaulted expansion so an unset variable
doesn't error. Replace the existing if test (referencing DISCONNECTED) with a
guarded form like if [ "${DISCONNECTED:-}" = "true" ]; then (or use
"${DISCONNECTED:-false}") and keep sourcing "${SHARED_DIR}/proxy-conf.sh"
unchanged so the script continues to work when DISCONNECTED is unset.
ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh (1)

13-19: ⚠️ Potential issue | 🔴 Critical | ⚡ Quick win

Prevent nounset failure in DISCONNECTED check.

Direct ${DISCONNECTED} expansion is unsafe with set -o nounset; default it in the condition.

Suggested patch
-if [ "${DISCONNECTED}" == "true" ]; then
+if [ "${DISCONNECTED:-false}" == "true" ]; then
   [ ! -f "${SHARED_DIR}/proxy-conf.sh" ] && {
     echo "Proxy conf file is not found. Failing."
     exit 1
   }
   source "${SHARED_DIR}/proxy-conf.sh"
 fi
#!/bin/bash
set -euo pipefail

FILE="ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh"
nl -ba "$FILE" | sed -n '1,30p'
echo "--- nounset + unguarded DISCONNECTED check ---"
rg -n 'set -o nounset|"\$\{DISCONNECTED\}"' "$FILE"
🤖 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/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh`
around lines 13 - 19, The conditional directly expands DISCONNECTED which will
fail under nounset; update the if test around DISCONNECTED to use a
default/empty expansion (use the ${DISCONNECTED:-} form) and ensure the POSIX
test operator is used (use = rather than ==) so the guard becomes safe under set
-o nounset; keep the rest of the block (checking SHARED_DIR/proxy-conf.sh and
sourcing it) unchanged and still quoted.
🤖 Prompt for all review comments with 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.

Duplicate comments:
In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh`:
- Around line 13-19: The check if [ "${DISCONNECTED}" == "true" ] can fail under
set -o nounset when DISCONNECTED is unset; change the condition to use a
defaulted expansion like ${DISCONNECTED:-} (i.e., reference DISCONNECTED with a
fallback) so the shell won't error on nounset. Update the conditional that
references DISCONNECTED in the installation script (the if block that sources
proxy-conf.sh and checks SHARED_DIR/proxy-conf.sh) to use the defaulted
expansion and keep the rest of the logic unchanged.

In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh`:
- Around line 22-28: The check against DISCONNECTED is unsafe under set -o
nounset; update the conditional to use defaulted expansion so an unset variable
doesn't error. Replace the existing if test (referencing DISCONNECTED) with a
guarded form like if [ "${DISCONNECTED:-}" = "true" ]; then (or use
"${DISCONNECTED:-false}") and keep sourcing "${SHARED_DIR}/proxy-conf.sh"
unchanged so the script continues to work when DISCONNECTED is unset.

In
`@ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh`:
- Around line 13-19: The conditional directly expands DISCONNECTED which will
fail under nounset; update the if test around DISCONNECTED to use a
default/empty expansion (use the ${DISCONNECTED:-} form) and ensure the POSIX
test operator is used (use = rather than ==) so the guard becomes safe under set
-o nounset; keep the rest of the block (checking SHARED_DIR/proxy-conf.sh and
sourcing it) unchanged and still quoted.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Enterprise

Run ID: 8e8ccc2c-a8a9-474f-b731-64c7d33e583d

📥 Commits

Reviewing files that changed from the base of the PR and between d8c1ba9 and c9a76ac.

📒 Files selected for processing (8)
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-commands.sh
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh
✅ Files skipped from review due to trivial changes (3)
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/agent-qe-baremetal-install-ove-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/assisted-ui/agent-qe-baremetal-install-ove-disconnected-assisted-ui-ref.yaml
  • ci-operator/step-registry/agent-qe/baremetal/install/ove/disconnected/agent-tui/agent-qe-baremetal-install-ove-disconnected-agent-tui-ref.yaml
🚧 Files skipped from review as they are similar to previous changes (2)
  • ci-operator/config/openshift-eng/agent-qe-infra/openshift-eng-agent-qe-infra-release-4.21__amd64-nightly.yaml
  • ci-operator/step-registry/baremetal/lab/pre/serial-console/baremetal-lab-pre-serial-console-commands.sh

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

[REHEARSALNOTIFIER]
@mhanss: the pj-rehearse plugin accommodates running rehearsal tests for the changes in this PR. Expand 'Interacting with pj-rehearse' for usage details. The following rehearsable tests have been affected by this change:

Test name Repo Type Reason
periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact N/A periodic Periodic changed
periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-agent-ipv4-disc-f60 N/A periodic Registry content changed
periodic-ci-openshift-eng-agent-qe-infra-release-4.20-amd64-nightly-baremetal-ove-compact-agent-ipv4-disc-f60 N/A periodic Registry content changed
periodic-ci-openshift-eng-agent-qe-infra-release-4.19-amd64-stable-baremetal-ove-compact-agent-ipv4-disc-f60 N/A periodic Registry content changed
periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-disc-konflux N/A periodic Registry content changed
periodic-ci-openshift-eng-agent-qe-infra-release-4.21-amd64-nightly-baremetal-ove-compact-konflux N/A periodic Registry content changed
Interacting with pj-rehearse

Comment: /pj-rehearse to run up to 5 rehearsals
Comment: /pj-rehearse skip to opt-out of rehearsals
Comment: /pj-rehearse {test-name}, with each test separated by a space, to run one or more specific rehearsals
Comment: /pj-rehearse more to run up to 10 rehearsals
Comment: /pj-rehearse max to run up to 25 rehearsals
Comment: /pj-rehearse auto-ack to run up to 5 rehearsals, and add the rehearsals-ack label on success
Comment: /pj-rehearse list to get an up-to-date list of affected jobs
Comment: /pj-rehearse abort to abort all active rehearsals
Comment: /pj-rehearse network-access-allowed to allow rehearsals of tests that have the restrict_network_access field set to false. This must be executed by an openshift org member who is not the PR author

Once you are satisfied with the results of the rehearsals, comment: /pj-rehearse ack to unblock merge. When the rehearsals-ack label is present on your PR, merge will no longer be blocked by rehearsals.
If you would like the rehearsals-ack label removed, comment: /pj-rehearse reject to re-block merging.

@pamoedom
Copy link
Copy Markdown
Contributor

pamoedom commented Jun 1, 2026

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2026
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Jun 1, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mhanss, pamoedom

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

@mhanss
Copy link
Copy Markdown
Contributor Author

mhanss commented Jun 1, 2026

/pj-rehearse ack

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

@mhanss: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-merge-bot openshift-merge-bot Bot added the rehearsals-ack Signifies that rehearsal jobs have been acknowledged label Jun 1, 2026
@openshift-merge-bot openshift-merge-bot Bot merged commit 185e2d4 into openshift:main Jun 1, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. rehearsals-ack Signifies that rehearsal jobs have been acknowledged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants