Skip to content

trusted-execution-clusters: Enable full suite - #82662

Draft
Jakob-Naucke wants to merge 2 commits into
openshift:mainfrom
Jakob-Naucke:tec-azure-full
Draft

trusted-execution-clusters: Enable full suite#82662
Jakob-Naucke wants to merge 2 commits into
openshift:mainfrom
Jakob-Naucke:tec-azure-full

Conversation

@Jakob-Naucke

@Jakob-Naucke Jakob-Naucke commented Jul 30, 2026

Copy link
Copy Markdown
Member

Following up on #79393. Debug first.

Summary by CodeRabbit

  • Adds the trusted-execution-clusters CI/operator configuration for the main branch, including a basic builder image stream tag and default CPU requests.
  • Introduces the Azure-specific CI configuration to build only azure-test-image, based on the OCP 4.21 CLI image, by copying in the oc binary and installing tooling needed by the tests.
  • Registers an optional Azure integration-test step (trusted-execution-clusters-ref-azure-integration-test) wired to an AWS IPI-based cluster profile (ipi-aws), with Azure credentials mounted from /tmp/secrets/azure.
  • Adds the Azure integration-test step implementation script, which authenticates to Azure via service principal, installs cert-manager dynamically, and runs make integration-tests in a loop until it fails.
  • Updates step ownership metadata by adding a symlinked OWNERS file and a corresponding ref metadata JSON for the new Azure integration-test reference.

Use native OpenShift as Trustee platform, attest Azure VM against
it. Optional test.

Signed-off-by: Jakob Naucke <jnaucke@redhat.com>
Assisted-by: Claude Opus 4.6
@openshift-ci openshift-ci Bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 30, 2026
@openshift-ci

openshift-ci Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@openshift-ci

openshift-ci Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Jakob-Naucke

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

@coderabbitai

coderabbitai Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

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

Review profile: CHILL

Plan: Pro Plus

Run ID: cb96dc49-aabf-4c4c-b633-7b7441285a8b

📥 Commits

Reviewing files that changed from the base of the PR and between 0f6b409 and 13cb31e.

📒 Files selected for processing (3)
  • ci-operator/config/trusted-execution-clusters/operator/trusted-execution-clusters-operator-main__azure.yaml
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-ref.yaml
💤 Files with no reviewable changes (2)
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-ref.yaml
  • ci-operator/config/trusted-execution-clusters/operator/trusted-execution-clusters-operator-main__azure.yaml

Walkthrough

Adds operator CI configurations and wires an Azure integration test reference that provisions tooling and cert-manager before repeatedly running integration tests.

Changes

Azure CI integration

Layer / File(s) Summary
Operator CI configuration
ci-operator/config/trusted-execution-clusters/operator/*
Adds the main configuration and configures the Azure variant to build only azure-test-image, while retaining OpenShift 4.21 release, resource, and integration-test settings.
Integration reference contract
ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-ref.yaml, ...ref.metadata.json, .../OWNERS
Defines the Azure test reference, credentials, resources, metadata, and delegated ownership without related-image dependencies.
Azure test environment and execution
ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh
Installs tooling, authenticates to Azure, prepares the repository and cluster, installs cert-manager, and repeatedly runs integration tests.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CI as CI configuration
  participant Ref as Azure integration ref
  participant Script as Commands script
  participant Azure as Azure CLI
  participant Cluster as OpenShift cluster
  participant Tests as Integration tests
  CI->>Ref: Select azure-test-image and test ref
  Ref->>Script: Execute Azure test commands
  Script->>Azure: Login with service-principal credentials
  Script->>Cluster: Apply cert-manager manifest
  Script->>Tests: Run make integration-tests repeatedly
Loading
🚥 Pre-merge checks | ✅ 14 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Ipv6 And Disconnected Network Test Compatibility ⚠️ Warning FAIL: the new integration-test script downloads rustup/azure-cli, fetches cert-manager from GitHub, and logs into Azure, so it needs public internet. Add [Skipped:Disconnected] or remove public-network dependencies; this job uses rustup, PyPI, GitHub, and Azure endpoints.
✅ Passed checks (14 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title matches the PR’s main goal of enabling the trusted-execution-clusters full CI/test suite, even if it is broader than the file-level changes.
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 No Ginkgo test titles were added or modified in the changed files; only CI config and shell scripts changed.
Test Structure And Quality ✅ Passed PR only changes CI YAML and a shell integration script; no Ginkgo tests or Expect/BeforeEach/Eventually patterns were modified.
Microshift Test Compatibility ✅ Passed PASS: The PR only changes CI config and a shell wrapper; no new Ginkgo tests were added, and the touched files contain no MicroShift-unsupported OpenShift APIs.
Single Node Openshift (Sno) Test Compatibility ✅ Passed No Ginkgo e2e tests were added; the PR only changes CI operator config and the Azure test wrapper, so the SNO compatibility check is not applicable.
Topology-Aware Scheduling Compatibility ✅ Passed Only CI config and test scripts changed; no deployment manifests, controllers, or pod scheduling fields were introduced.
Ote Binary Stdout Contract ✅ Passed No Go OTE binary code changed; only CI YAML and a step-registry shell script, whose echo lines are not process-level binary stdout.
No-Weak-Crypto ✅ Passed Full PR diff shows CI YAML and shell orchestration only; no MD5/SHA1/DES/RC4/3DES/Blowfish/ECB, custom crypto, or secret comparisons found.
Container-Privileges ✅ Passed No privileged, host*, SYS_ADMIN, or allowPrivilegeEscalation settings were added in the changed manifests; diff only updates build/test config.
No-Sensitive-Data-In-Logs ✅ Passed No sensitive data is logged; added output is generic, and secrets are only read from mounted files and passed to commands.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

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

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 30, 2026
@Jakob-Naucke

Copy link
Copy Markdown
Member Author

/pj-rehearse

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

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

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 3

🧹 Nitpick comments (1)
ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh (1)

10-10: 🔒 Security & Privacy | 🔵 Trivial | ⚡ Quick win

Pin the Azure CLI dependency.

pip install azure-cli resolves the package and all transitive dependencies at job runtime, allowing unrelated releases to change or break this test. Use a reviewed constraint/lock file with hashes or bake the pinned version into azure-test-image.

🤖 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/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`
at line 10, Update the Azure CLI installation command in the trusted execution
cluster test setup to use a reviewed pinned dependency source, such as a
constraints/lock file with hashes, or replace the runtime install with the
pinned Azure CLI version from azure-test-image. Ensure transitive dependencies
are reproducibly constrained rather than resolved freely at job runtime.
🤖 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/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`:
- Around line 40-43: Update the attestation test execution around the make
attestation-tests loop to avoid unbounded retries and ensure a final test
failure makes the step exit non-zero. Prefer running make attestation-tests once
for normal CI, or implement a bounded retry with an explicit failure exit after
the retry limit.
- Around line 28-30: Remove the `git remote add test`, `git fetch test`, and
`git switch timed-client-ci` overrides so normal CI runs the reviewed checkout;
also remove the mutable personal Quay image override at the corresponding
image-selection symbols. If debugging support is required, isolate it behind an
explicit manual path and pin the source revision by commit and image by digest.
- Line 5: Replace the direct curl-to-shell invocation with a pinned or prebuilt
Rust toolchain in the trusted execution setup. If retaining the installer,
download it to a local file, verify its reviewed checksum or signature, and only
then execute it; ensure no unverified remote content runs with access to Azure
secrets.

---

Nitpick comments:
In
`@ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`:
- Line 10: Update the Azure CLI installation command in the trusted execution
cluster test setup to use a reviewed pinned dependency source, such as a
constraints/lock file with hashes, or replace the runtime install with the
pinned Azure CLI version from azure-test-image. Ensure transitive dependencies
are reproducibly constrained rather than resolved freely at job runtime.
🪄 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: Pro Plus

Run ID: 77d53dd0-d4ab-4b7e-a12b-3bbd7a72d084

📥 Commits

Reviewing files that changed from the base of the PR and between 5bcc8d8 and 0f6b409.

⛔ Files ignored due to path filters (1)
  • ci-operator/jobs/trusted-execution-clusters/operator/trusted-execution-clusters-operator-main-presubmits.yaml is excluded by !ci-operator/jobs/**
📒 Files selected for processing (6)
  • ci-operator/config/trusted-execution-clusters/operator/trusted-execution-clusters-operator-main.yaml
  • ci-operator/config/trusted-execution-clusters/operator/trusted-execution-clusters-operator-main__azure.yaml
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/OWNERS
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-ref.metadata.json
  • ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-ref.yaml


set -euo pipefail

curl https://sh.rustup.rs | sh -s -- -y

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.

🔒 Security & Privacy | 🟠 Major | 🏗️ Heavy lift

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -u

# Locate and inspect the target command script and nearby context.
target="ci-operator/step-registry/${PWD##*/}/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh"
if [ -f "$target" ]; then
  wc -l "$target"
  sed -n '1,80p' "$target" | cat -n
else
  echo "Target not found: $target"
fi

echo '--- matching command scripts ---'
fd -a 'trusted-execution-clusters-ref-azure-integration-test-commands.sh' . || true

echo '--- rustup/azure credential usage ---'
rg -n 'curl .*rustup|rustup|azure|AZURE|[A-Z_]*SECRET|/tmp/secrets|ssh-agent|SHARED_DIR' ci-operator/step-registry 2>/dev/null | head -200

Repository: openshift/release

Length of output: 36470


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Locate and inspect the target command script and nearby context.
target="ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh"
if [ -f "$target" ]; then
  echo "== file stats =="
  wc -l "$target"
  echo "== target content =="
  sed -n '1,120p' "$target" | cat -n
else
  echo "Target not found: $target"
fi

echo '--- matching command scripts ---'
fd -a 'trusted-execution-clusters-ref-azure-integration-test-commands.sh' . || true

echo '--- rustup/azure credential usage ---'
rg -n 'curl .*rustup|rustup|azure|AZURE|[A-Z_]*SECRET|/tmp/secrets|ssh-agent|SHARED_DIR' ci-operator/step-registry 2>/dev/null | head -200

Repository: openshift/release

Length of output: 35715


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Locate and inspect the target command script and nearby context.
target="ci-operator/step-registry/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh"
if [ -f "$target" ]; then
  echo "== file stats =="
  wc -l "$target"
  echo "== target content =="
  sed -n '1,120p' "$target" | cat -n
else
  echo "Target not found: $target"
  echo "candidate files:"
  fd -a 'trusted-execution-clusters-ref-azure-integration-test-commands.sh' . || true
fi

echo '--- rustup/azure credential usage ---'
rg -n 'curl .*rustup|rustup|azure|AZURE|[A-Z_]*SECRET|/tmp/secrets|ssh-agent|SHARED_DIR' ci-operator/step-registry 2>/dev/null | head -200

Repository: openshift/release

Length of output: 37951


Do not pipe an unverified remote script into the shell.

Line 5 executes mutable remote content directly before Azure credentials are loaded, and the script runs with access to /tmp/secrets/azure. Use a pinned/prebuilt Rust toolchain instead, or download the installer and verify a reviewed checksum/signature before executing the local 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/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`
at line 5, Replace the direct curl-to-shell invocation with a pinned or prebuilt
Rust toolchain in the trusted execution setup. If retaining the installer,
download it to a local file, verify its reviewed checksum or signature, and only
then execute it; ensure no unverified remote content runs with access to Azure
secrets.

Source: Linters/SAST tools

Comment on lines +28 to +30
git remote add test https://github.com/Jakob-Naucke/trusted-cluster-operator
git fetch test
git switch timed-client-ci

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.

🔒 Security & Privacy | 🔴 Critical | 🏗️ Heavy lift

Do not run a mutable personal fork with CI cloud credentials.

Lines 28-30 replace the PR checkout with Jakob-Naucke/trusted-cluster-operator:timed-client-ci. Azure authentication has already occurred on Lines 21-24, so make attestation-tests executes unreviewed fork code with cloud authentication. Lines 32-33 also select a mutable personal Quay image instead of a CI-built immutable artifact. Remove these overrides for normal CI; keep debugging branches/images isolated behind an explicit manual path and pin any required revision by commit/digest.

Also applies to: 32-33

🤖 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/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`
around lines 28 - 30, Remove the `git remote add test`, `git fetch test`, and
`git switch timed-client-ci` overrides so normal CI runs the reviewed checkout;
also remove the mutable personal Quay image override at the corresponding
image-selection symbols. If debugging support is required, isolate it behind an
explicit manual path and pin the source revision by commit and image by digest.

Comment on lines +40 to +43
echo "[INFO] Running attestation tests until failure..."
while make attestation-tests
do :
done

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

Make failures fail the step and bound the loop.

With make in the while condition, set -e does not propagate its failure. After any successful iteration, the final : makes the loop return zero when make eventually fails; if tests always pass, the job runs indefinitely. Remove the loop for normal CI or use a bounded retry loop so failures exit non-zero.

🤖 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/trusted-execution-clusters/ref/azure-integration-test/trusted-execution-clusters-ref-azure-integration-test-commands.sh`
around lines 40 - 43, Update the attestation test execution around the make
attestation-tests loop to avoid unbounded retries and ensure a final test
failure makes the step exit non-zero. Prefer running make attestation-tests once
for normal CI, or implement a bounded retry with an explicit failure exit after
the retry limit.

Following up on openshift#79393. Debug first.

Signed-off-by: Jakob Naucke <jnaucke@redhat.com>
@Jakob-Naucke

Copy link
Copy Markdown
Member Author

Infinite loop was successful until timeout. Promising. Let's give it another go including cluster-level tests, which I forgot earlier.

/pj-rehearse

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@Jakob-Naucke: 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]
@Jakob-Naucke: 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
pull-ci-trusted-execution-clusters-operator-main-azure-images trusted-execution-clusters/operator presubmit Presubmit changed
pull-ci-trusted-execution-clusters-operator-main-azure-integration-test trusted-execution-clusters/operator presubmit Presubmit changed
pull-ci-trusted-execution-clusters-operator-main-images trusted-execution-clusters/operator presubmit Presubmit 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.

@openshift-ci

openshift-ci Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

@Jakob-Naucke: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/rehearse/trusted-execution-clusters/operator/main/azure-integration-test 13cb31e link unknown /pj-rehearse pull-ci-trusted-execution-clusters-operator-main-azure-integration-test

Full PR test history. Your PR dashboard.

Details

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 kubernetes-sigs/prow repository. I understand the commands that are listed here.

@Jakob-Naucke

Copy link
Copy Markdown
Member Author

adding up, 4 good runs in a row (failure is from timeout)

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. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant