Skip to content

Support FIPS mode via feature flags & cluster tags#5333

Draft
mzazrivec wants to merge 1 commit into
Azure:mainfrom
mzazrivec:support_fips_via_feature_flags
Draft

Support FIPS mode via feature flags & cluster tags#5333
mzazrivec wants to merge 1 commit into
Azure:mainfrom
mzazrivec:support_fips_via_feature_flags

Conversation

@mzazrivec
Copy link
Copy Markdown
Contributor

What

This pull request adds the ability to provision a new ARO-HCP cluster in FIPS mode using Azure feature flags & cluster tag fips-enabled.

Why

Testing

Special notes for your reviewer

PR Checklist

  • PR is scoped to a single task (no mixed concerns)
  • Title follows Conventional Commits format
  • Summary explains the "Why" behind the change
  • Linked to relevant ticket/issue
  • Screenshots included (if graph/UI/metrics changes)
  • Self-reviewed the diff
  • CI/CD checks are passing (ignore Tide)
  • Draft PR used for WIP (if applicable)
  • Commit history is clean (rebased/squashed)
  • Tricky code blocks are commented
  • Specific reviewers tagged
  • All comment threads resolved before merge

Copilot AI review requested due to automatic review settings May 19, 2026 19:53
@openshift-ci openshift-ci Bot requested review from deads2k and mbarnes May 19, 2026 19:53
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 19, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mzazrivec
Once this PR has been reviewed and has the lgtm label, please assign mbarnes 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

@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 19, 2026

Hi @mzazrivec. Thanks for your PR.

I'm waiting for a Azure member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds support for provisioning new ARO-HCP clusters in FIPS mode, controlled via an Azure feature flag and an ARM cluster tag (fips-enabled).

Changes:

  • Adds FipsEnabled to experimental feature configuration and maps it into ClusterService cluster builder.
  • Introduces a new ARM tag constant and admission mutation logic to parse/validate the tag and set ExperimentalFeatures.FipsEnabled.
  • Extends cluster customer properties with a fipsEnabled field.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
internal/ocm/convert.go Plumbs ExperimentalFeatures.FipsEnabled into the CS cluster builder (FIPS flag).
internal/api/types_experimental.go Adds FipsEnabled to experimental feature type and defines string constants for tag parsing.
internal/api/types_cluster.go Adds FipsEnabled to customer properties (JSON).
internal/api/featureflags.go Adds tag constant for enabling FIPS via ARM tags.
internal/admission/admit_cluster.go Reads fips-enabled tag and sets experimentalFeatures.FipsEnabled / validates values.

Comment thread internal/api/types_cluster.go Outdated
Etcd EtcdProfile `json:"etcd,omitempty"`
ClusterImageRegistry ClusterImageRegistryProfile `json:"clusterImageRegistry,omitempty"`
ImageDigestMirrors []ImageDigestMirror `json:"imageDigestMirrors,omitempty"`
FipsEnabled bool `json:"fipsEnabled`
Comment on lines +88 to +99
fipsEnabled := lookupTag(tags, api.TagClusterFipsEnabled)
switch fipsEnabled {
case api.FipsModeEnabled:
experimentalFeatures.FipsEnabled = true
case api.FipsModeDisabled:
experimentalFeatures.FipsEnabled = false
default:
errs = append(errs, field.Invalid(
fldPath.Key(api.TagClusterFipsEnabled), fipsEnabled,
fmt.Sprintf("must be %s or %s", api.FipsModeEnabled, api.FipsModeDisabled),
))
}
Comment thread internal/api/featureflags.go Outdated
// TagClusterFipsEnabled is the ARM resource tag that enables FIPS mode
// for the ARO-HCP cluster during installation when the ExperimentalReleaseFeatures
// AFEC is registered on the subscription.
TagClusterFipsEnabled = "fips-enabled"
Comment thread internal/api/types_experimental.go Outdated
ControlPlanePodSizing ControlPlanePodSizing `json:"sizeOverride,omitempty"`

// FipsEnabled controls the fips mode for the installation of a new ARO-HCP cluster.
FipsEnabled bool `json:"fipsEnabled"`
Comment thread internal/ocm/convert.go Outdated
Comment on lines +422 to +426
if experimentalFeatures.FipsEnabled {
clusterBuilder.FIPS(true)
} else {
clusterBuilder.FIPS(false)
}
@mzazrivec mzazrivec force-pushed the support_fips_via_feature_flags branch 2 times, most recently from a0dd1bd to f70aae7 Compare May 21, 2026 14:58
@mzazrivec mzazrivec force-pushed the support_fips_via_feature_flags branch from f70aae7 to 97c553a Compare May 21, 2026 17:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants