Skip to content

CORS-4308: networking: enforce NetworkObservabilityInstall feature gate - #10774

Open
stleerh wants to merge 1 commit into
openshift:mainfrom
stleerh:enforce-feature-gate
Open

CORS-4308: networking: enforce NetworkObservabilityInstall feature gate#10774
stleerh wants to merge 1 commit into
openshift:mainfrom
stleerh:enforce-feature-gate

Conversation

@stleerh

@stleerh stleerh commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

When running openshift-install, this checks that the NetworkObservabilityInstall feature gate is enabled before allowing the networkObservability field in install-config.yaml.

Summary by CodeRabbit

  • New Features

    • Added feature-gate validation for Network Observability configuration.
    • Network Observability can now be enabled when the required TechPreview feature set is active.
  • Bug Fixes

    • Installation configurations that enable Network Observability without the required feature gate are now rejected with a clear validation error.

@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: LGTM mode

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Aug 19, 2026
@openshift-ci-robot

openshift-ci-robot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

@stleerh: This pull request references CORS-4308 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.1.0" version, but no target version was set.

Details

In response to this:

When running openshift-install, this checks that the NetworkObservabilityInstall feature gate is enabled before allowing the networkObservability field in install-config.yaml.

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 openshift-eng/jira-lifecycle-plugin repository.

@stleerh

stleerh commented Aug 19, 2026

Copy link
Copy Markdown
Contributor Author

If you want to enable this feature gate, add this to your install-config.yaml file.

featureSet: TechPreviewNoUpgrade

-or-

featureSet: CustomNoUpgrade
featureGates:
  - NetworkObservabilityInstall=true

To not enable Network Observability, add this to your install-config.yaml file. Of course, you have to have the feature gate enabled to do this.

networking:
  networkObservability:
    installationPolicy: NoAction

@coderabbitai

coderabbitai Bot commented Aug 19, 2026

Copy link
Copy Markdown

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: a05ee697-7400-4d6d-a737-0e8709f6929b

📥 Commits

Reviewing files that changed from the base of the PR and between a8f8c36 and 8372908.

📒 Files selected for processing (2)
  • pkg/types/validation/installconfig.go
  • pkg/types/validation/installconfig_test.go

Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review.


📝 Walkthrough

Walkthrough

Changes

Network observability feature gate

Layer / File(s) Summary
Register network observability gate
pkg/types/validation/installconfig.go
Registers NetworkObservabilityInstall for networking.networkObservability validation.
Validate enabled and disabled gate behavior
pkg/types/validation/installconfig_test.go
Updates valid and invalid cases to enable TechPreviewNoUpgrade. Adds coverage for forbidden configuration without the required feature gate.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: ⚪ Minimal · up to 83729

This localized validation change is merge-ready after normal checks and review, with no actionable merge-blocking risk remaining.

🚥 Pre-merge checks | ✅ 14 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ 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 clearly and concisely describes enforcement of the NetworkObservabilityInstall feature gate.
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 The diff adds only the static table-test name "networkObservability feature gate disabled"; no Ginkgo titles or runtime interpolation were introduced.
Test Structure And Quality ✅ Passed The changed tests are standard Go table tests, not Ginkgo tests. They use existing t.Run/assert patterns, create no cluster resources, and perform no waits requiring timeouts.
Microshift Test Compatibility ✅ Passed The PR adds Go unit-test cases in pkg/types/validation, not new Ginkgo e2e tests; the MicroShift compatibility check is therefore inapplicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed The diff adds only standard Go table-driven unit-test cases in pkg/types/validation; it adds no Ginkgo e2e tests or multi-node assumptions.
Topology-Aware Scheduling Compatibility ✅ Passed The diff only updates install-config feature-gate validation and tests. It adds no manifests, operators, controllers, replicas, affinity, selectors, tolerations, or other scheduling constraints.
Ote Binary Stdout Contract ✅ Passed The diff only adds feature-gate validation and test data. It adds no process-level stdout writes; the existing fmt.Println is unchanged and runs inside a test setup closure.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed The PR adds only ordinary Go unit-test cases in TestValidateInstallConfig; it adds no Ginkgo e2e tests, IPv4 assumptions, or external connectivity requirements.
No-Weak-Crypto ✅ Passed The diff adds a feature-gate check and tests only. It introduces no MD5, SHA1, DES, RC4, Blowfish, ECB, custom crypto, or secret comparisons.
Container-Privileges ✅ Passed The PR changes only Go validation code and tests. The exact diff adds no container/Kubernetes manifests or privilege settings such as privileged, hostPID, hostNetwork, hostIPC, SYS_ADMIN, or allowP...
No-Sensitive-Data-In-Logs ✅ Passed The diff adds feature-gate validation and tests only. It introduces no logging calls or log messages containing sensitive data.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.12.2)

Error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions
The command is terminated due to an error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions


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 bfournie and sadasu August 19, 2026 16:05
@stleerh

stleerh commented Aug 19, 2026

Copy link
Copy Markdown
Contributor Author

/retest

@stleerh

stleerh commented Aug 20, 2026

Copy link
Copy Markdown
Contributor Author

/test e2e-aws-ovn

2 similar comments
@stleerh

stleerh commented Aug 20, 2026

Copy link
Copy Markdown
Contributor Author

/test e2e-aws-ovn

@stleerh

stleerh commented Aug 20, 2026

Copy link
Copy Markdown
Contributor Author

/test e2e-aws-ovn

@stleerh

stleerh commented Aug 21, 2026

Copy link
Copy Markdown
Contributor Author

/retest

1 similar comment
@stleerh

stleerh commented Aug 21, 2026

Copy link
Copy Markdown
Contributor Author

/retest

@sadasu sadasu 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.

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Aug 21, 2026
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Tests from second stage were triggered manually. Pipeline can be controlled only manually, until HEAD changes. Use command to trigger second stage.

@openshift-ci

openshift-ci Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sadasu

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

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

openshift-ci Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

@stleerh: all tests passed!

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.

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. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants