Skip to content

PowerVS : Create new powervs-sno lease#5290

Draft
mpkredhat wants to merge 1 commit into
openshift:mainfrom
mpkredhat:br-827
Draft

PowerVS : Create new powervs-sno lease#5290
mpkredhat wants to merge 1 commit into
openshift:mainfrom
mpkredhat:br-827

Conversation

@mpkredhat

@mpkredhat mpkredhat commented Jul 2, 2026

Copy link
Copy Markdown
Member

Requesting powervs-sno lease within dal14 workspace and quota-slice as 2.

Adds support for a new PowerVS SNO cluster profile in the CI tooling. In practice, this lets CI operators request and classify a powervs-sno lease in the dal14 workspace using quota-slice 2, with the API now recognizing the new cluster type and automatically mapping it to the corresponding powervs-sno-quota-slice lease type.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci openshift-ci Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 2, 2026
@openshift-ci

openshift-ci Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

PR needs rebase.

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.

@coderabbitai

coderabbitai Bot commented Jul 2, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

Adds a new ClusterProfilePOWERVSSNO constant to the ClusterProfile type and wires it into ClusterType(), LeaseType(), and LeaseTypeFromClusterType() so the new profile resolves to "powervs-sno" cluster type and "powervs-sno-quota-slice" lease type.

Changes

POWERVS SNO cluster profile support

Layer / File(s) Summary
Add constant and wire mapping functions
pkg/api/clusterprofile.go
Adds ClusterProfilePOWERVSSNO constant and extends ClusterType(), LeaseType(), and LeaseTypeFromClusterType() switch/mapping logic to support it.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Related PRs: None identified from provided context.

Suggested labels: none

Suggested reviewers: none

🐇 A tiny hop, a new profile grows,
"powervs-sno" now the cluster knows,
Lease slices quota, types align,
Four small lines, one neat design.

🚥 Pre-merge checks | ✅ 16 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Test Coverage For New Features ⚠️ Warning New powervs-sno mapping branches were added, but no tests cover powervs-sno or LeaseTypeFromClusterType, and ClusterProfiles() doesn’t include the new constant. Add table-driven unit tests for ClusterType, LeaseType, and LeaseTypeFromClusterType covering powervs-sno, and include the new profile in any enum/list-based coverage.
✅ Passed checks (16 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: adding a new PowerVS powervs-sno lease/profile mapping.
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.
Go Error Handling ✅ Passed Added code uses fmt.Errorf/%w for failures, no panic or ignored errors were introduced, and nil params are checked before dereference.
Stable And Deterministic Test Names ✅ Passed PR only changes clusterprofile constants/mapping in non-test code; no Ginkgo test titles were added or modified.
Test Structure And Quality ✅ Passed Only pkg/api/clusterprofile.go changed; no Ginkgo tests were added or modified, so the test-structure/quality check is not applicable.
Microshift Test Compatibility ✅ Passed No standalone Ginkgo specs were added; changed e2e tests use testing.T only, so the MicroShift compatibility check is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed PR only adds a cluster profile constant and lease/type mappings; no new Ginkgo e2e tests or multi-node assumptions were introduced.
Topology-Aware Scheduling Compatibility ✅ Passed PR only adds a new cluster profile/lease string mapping in pkg/api/clusterprofile.go; no manifests, controllers, pod specs, or scheduling constraints were added.
Ote Binary Stdout Contract ✅ Passed PR only adds a new ClusterProfile constant and pure mapping cases; no process-level stdout writes were introduced.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed No new Ginkgo e2e tests were added; the PR only updates cluster profile mappings in pkg/api/clusterprofile.go.
No-Weak-Crypto ✅ Passed PASS: pkg/api/clusterprofile.go only adds cluster-profile constants/mappings; no MD5/SHA1/DES/RC4/ECB, custom crypto, or secret comparisons were introduced.
Container-Privileges ✅ Passed PR only changes clusterprofile.go enum/mapping for powervs-sno; no container/K8s manifest or privilege settings were added.
No-Sensitive-Data-In-Logs ✅ Passed Only cluster-profile constants and pure mapping functions changed; no logger imports/calls or sensitive strings were added.
✨ 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 requested review from bear-redhat and pruan-rht July 2, 2026 10:34
@openshift-ci

openshift-ci Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mpkredhat
Once this PR has been reviewed and has the lgtm label, please assign jmguzik for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@mpkredhat mpkredhat marked this pull request as draft July 2, 2026 10:39
@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 2, 2026
@openshift-ci

openshift-ci Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

@mpkredhat: The following tests 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/prow/secret-generator-validation 10aba23 link false /test secret-generator-validation
ci/prow/lint 10aba23 link true /test lint
ci/prow/unit 10aba23 link true /test unit
ci/prow/validate-vendor 10aba23 link true /test validate-vendor
ci/prow/integration 10aba23 link true /test integration
ci/prow/security 10aba23 link false /test security
ci/prow/format 10aba23 link true /test format
ci/prow/breaking-changes 10aba23 link false /test breaking-changes
ci/prow/validate-prow 10aba23 link true /test validate-prow
ci/prow/images 10aba23 link true /test images
ci/prow/secret-bootstrapper-validation 10aba23 link false /test secret-bootstrapper-validation
ci/prow/frontend-checks 10aba23 link true /test frontend-checks

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
pkg/api/clusterprofile.go (1)

961-962: 🧹 Nitpick | 🔵 Trivial

Confirm Boskos pool exists for the new lease type.

LeaseType() now returns "powervs-sno-quota-slice", but the openshift/release Boskos config doesn't yet define a matching pool (only powervs-1powervs-9 and powervs-multi-1 slices exist there). Without that pool, jobs using this profile will fail to acquire leases at runtime.

Ensure core-services/prow/02_config/_boskos.yaml in openshift/release is updated with a powervs-sno-quota-slice pool before this profile is used by any job.

🤖 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 `@pkg/api/clusterprofile.go` around lines 961 - 962, The new LeaseType value
returned by ClusterProfilePOWERVSSNO is not backed by a matching Boskos pool, so
jobs will fail to acquire leases at runtime. Update the Boskos configuration to
add a pool named powervs-sno-quota-slice in
core-services/prow/02_config/_boskos.yaml, and make sure the
ClusterProfilePOWERVSSNO path in LeaseType stays aligned with that pool name.

Source: Linked repositories

🤖 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.

Nitpick comments:
In `@pkg/api/clusterprofile.go`:
- Around line 961-962: The new LeaseType value returned by
ClusterProfilePOWERVSSNO is not backed by a matching Boskos pool, so jobs will
fail to acquire leases at runtime. Update the Boskos configuration to add a pool
named powervs-sno-quota-slice in core-services/prow/02_config/_boskos.yaml, and
make sure the ClusterProfilePOWERVSSNO path in LeaseType stays aligned with that
pool name.

ℹ️ Review info
⚙️ Run configuration

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

Review profile: CHILL

Plan: Enterprise

Run ID: 0b3b0a76-5ed2-4824-b156-f8b7ddd333a0

📥 Commits

Reviewing files that changed from the base of the PR and between 01b066a and 10aba23.

📒 Files selected for processing (1)
  • pkg/api/clusterprofile.go
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • openshift/release (manual)
  • openshift/ci-docs (manual)
  • openshift/release-controller (manual)
  • openshift/ci-chat-bot (manual)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant