Skip to content

refactor(mgmt): make Swift VNet mandatory for management clusters - #6185

Merged
openshift-merge-bot[bot] merged 1 commit into
Azure:mainfrom
raelga:raelg/aroslsre-1548-swift-mandatory-mgmt
Jul 22, 2026
Merged

refactor(mgmt): make Swift VNet mandatory for management clusters#6185
openshift-merge-bot[bot] merged 1 commit into
Azure:mainfrom
raelga:raelg/aroslsre-1548-swift-mandatory-mgmt

Conversation

@raelga

@raelga raelga commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

AROSLSRE-1548

What

Makes Swift V2 VNet mandatory for management clusters and removes the
non-Swift code path for them.

  • Removes mgmt.aks.enableSwiftV2Vnet / mgmt.aks.enableSwiftV2Nodepools from
    config/config.yaml (default, the dev override, and all env overlays) and from
    config/config.schema.json; re-materialized config/rendered/.
  • Hardcodes enableSwift/enableSwiftV2Nodepools = true at the
    mgmt-cluster.bicep module call sites and removes the now-unused
    aksEnableSwiftVnet / aksEnableSwiftNodepools params + their tmpl.bicepparam
    values.
  • swift-vnet-permissions.bicep now grants the Swift VNet RBAC unconditionally
    (dropped the enableSwift param + gate).
  • Drops the ENABLE_SWIFT gate from the mgmt-pipeline swift-vnet step and
    scripts/swift-vnet.sh so the VNet create/tag always runs.

Service and opstool clusters are not management clusters and keep passing
enableSwift/enableSwiftV2Nodepools = false; the shared
aks-cluster-base / network/vnet / aks/pool modules retain the toggle for them.

Why

Management clusters already run Swift V2 in int/stg/prod — only the dev cloud
overrode the flags to false. Keeping a mgmt-level Swift toggle means carrying a
config knob that must never be flipped in production and a non-Swift code path
that is never exercised for management clusters. Removing it makes Swift the
single, enforced management-cluster networking mode and shrinks the config
surface. The dev-cloud blocker (SwiftV2 mgmt-node bring-up) has been cleared with
the owner, so dev/CSPR can move onto Swift.

Testing

  • bicep build of mgmt-cluster.bicep and swift-vnet-permissions.bicep compiles
    clean (pre-existing BCP334 warning in aks/pool.bicep is unrelated).
  • bash -n scripts/swift-vnet.sh passes.
  • cd config && make materialize re-renders with the flags removed; confirmed no
    enableSwiftV2Vnet/enableSwiftV2Nodepools config keys remain anywhere in the
    repo, and only management-cluster call sites are affected.

No automated test covers the mgmt bootstrap pipeline directly; validated via bicep
build + materialize + config-schema validation.

Special notes for your reviewer

The shared network/vnet.bicep and aks-cluster-base.bicep modules intentionally
keep their enableSwift/enableSwiftV2Nodepools params — service and opstool
clusters still deploy non-Swift. Only the management-cluster path is now
Swift-only.

…OSLSRE-1548)

Management clusters already run Swift V2 in int/stg/prod; only the dev cloud
overrode mgmt.aks.enableSwiftV2Vnet/enableSwiftV2Nodepools to false. Remove the
non-Swift path for management clusters so Swift is always on and the config
surface no longer carries a toggle that must never be flipped in production.

- drop enableSwiftV2Vnet/enableSwiftV2Nodepools from config.yaml (default, dev
  override and all env overlays) and config.schema.json, and re-materialize
- hardcode enableSwift/enableSwiftV2Nodepools = true at the mgmt-cluster.bicep
  module call sites; remove the aksEnableSwiftVnet/aksEnableSwiftNodepools params
  and their tmpl.bicepparam values
- make swift-vnet-permissions.bicep grant the Swift VNet RBAC unconditionally
  (remove the enableSwift param + tmpl.bicepparam value)
- drop the ENABLE_SWIFT gate from the mgmt-pipeline swift-vnet step and
  scripts/swift-vnet.sh so the create/tag always runs
- leave the shared aks-cluster-base/network/pool modules untouched: svc and
  opstool clusters keep passing enableSwift(V2Nodepools)=false

The shared cluster modules still expose the Swift toggle for service and opstool
clusters, which remain non-Swift.
Copilot AI review requested due to automatic review settings July 21, 2026 11:22
@openshift-ci
openshift-ci Bot requested review from ashishmax31 and weherdh July 21, 2026 11:22

Copilot AI 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.

Pull request overview

This PR refactors the management-cluster deployment path to make Swift V2 networking mandatory, removing the now-unused mgmt-level config toggles and eliminating the non-Swift management-cluster code path while preserving the Swift toggle for service/opstool clusters.

Changes:

  • Remove mgmt.aks.enableSwiftV2Vnet / mgmt.aks.enableSwiftV2Nodepools from config/config.yaml, config/config.schema.json, and re-materialized config/rendered/.
  • Hardcode Swift enabled for management clusters in mgmt-cluster.bicep (VNet and nodepools), and drop the corresponding bicep params/plumbing.
  • Make Swift VNet RBAC + Swift VNet create/tag pipeline steps unconditional for management clusters (remove ENABLE_SWIFT gating and enableSwift bicepparam).

Reviewed changes

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

Show a summary per file
File Description
dev-infrastructure/templates/swift-vnet-permissions.bicep Removes the enableSwift gate so Swift VNet RBAC is always applied for mgmt clusters.
dev-infrastructure/templates/mgmt-cluster.bicep Hardcodes Swift enabled for mgmt VNet and Swift V2 nodepools; removes now-unused params.
dev-infrastructure/scripts/swift-vnet.sh Removes ENABLE_SWIFT short-circuit so the Swift VNet create/tag always runs.
dev-infrastructure/mgmt-pipeline.yaml Makes Swift VNet permissions + create/tag steps unconditional and removes the ENABLE_SWIFT variable wiring.
dev-infrastructure/configurations/swift-vnet-permissions.tmpl.bicepparam Drops the removed enableSwift parameter.
dev-infrastructure/configurations/mgmt-cluster.tmpl.bicepparam Drops the removed Swift enable parameters for mgmt-cluster deployments.
config/config.yaml Removes the mgmt Swift toggle keys from defaults/overlays.
config/config.schema.json Removes the mgmt Swift toggle properties from the schema.
config/rendered/dev//.yaml Removes rendered mgmt Swift toggle keys (materialize output updated accordingly).

@roivaz

roivaz commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

/lgtm

@openshift-ci

openshift-ci Bot commented Jul 21, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: raelga, roivaz

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-merge-bot

Copy link
Copy Markdown
Contributor

/retest-required

Remaining retests: 0 against base HEAD 78c81c3 and 2 for PR HEAD bddadf7 in total

@raelga

raelga commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator Author

/retest-required

@raelga

raelga commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator Author

/test e2e-parallel

@openshift-merge-bot
openshift-merge-bot Bot merged commit 711799f into Azure:main Jul 22, 2026
17 checks passed
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.

3 participants