Skip to content

Commit

Permalink
Renamed ebpfDataPlane to networkDataplane to match current managedClu…
Browse files Browse the repository at this point in the history
…sters API spec
  • Loading branch information
pjlewisuk authored Apr 10, 2024
1 parent 32c1034 commit addb445
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"agentVMSize": {
"value": "Standard_DS3_v2"
},
"ebpfDataplane": {
"networkDataplane": {
"value": "cilium"
},
"networkPluginMode": {
Expand Down
4 changes: 2 additions & 2 deletions bicep/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -951,7 +951,7 @@ param networkPluginMode string = ''
'cilium'
])
@description('Use Cilium dataplane (requires azure networkPlugin)')
param ebpfDataplane string = ''
param networkDataplane string = ''

@allowed([
''
Expand Down Expand Up @@ -1303,7 +1303,7 @@ var aksProperties = union({
dnsServiceIP: dnsServiceIP
dockerBridgeCidr: dockerBridgeCidr
outboundType: outboundTrafficType
ebpfDataplane: networkPlugin=='azure' ? ebpfDataplane : ''
networkDataplane: networkPlugin=='azure' ? networkDataplane : ''
}
disableLocalAccounts: AksDisableLocalAccounts && enable_aad
autoUpgradeProfile: {upgradeChannel: upgradeChannel}
Expand Down
4 changes: 2 additions & 2 deletions helper/src/components/addonsTab.js
Original file line number Diff line number Diff line change
Expand Up @@ -365,8 +365,8 @@ export default function ({ tabValues, updateFn, featureFlag, invalidArray,showPr
errorMessage={getError(invalidArray, 'networkPolicy')}
options={[
{ "data-testid":'addons-netpolicy-none', key: 'none', text: 'No restrictions, all PODs can access each other' },
{ "data-testid":'addons-netpolicy-calico', disabled: net.ebpfDataplane, key: 'calico', text: 'Use Calico to implement intra-cluster traffic restrictions' },
{ "data-testid":'addons-netpolicy-azure', disabled: net.ebpfDataplane, key: 'azure', text: 'Use Azure NPM to implement intra-cluster traffic restrictions ' },
{ "data-testid":'addons-netpolicy-calico', disabled: net.networkDataplane, key: 'calico', text: 'Use Calico to implement intra-cluster traffic restrictions' },
{ "data-testid":'addons-netpolicy-azure', disabled: net.networkDataplane, key: 'azure', text: 'Use Azure NPM to implement intra-cluster traffic restrictions ' },
{ "data-testid":'addons-netpolicy-cilium', key: 'cilium', text: 'Use Cilium to implement intra-cluster traffic restrictions (requires Cilium backplane for CNI).' }
]}
onChange={(ev, { key }) => updateFn("networkPolicy", key)}
Expand Down
4 changes: 2 additions & 2 deletions helper/src/components/deployTab.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export default function DeployTab({ defaults, updateFn, tabValues, invalidArray,
...( addons.logDataCap !== defaults.addons.logDataCap && {logDataCap: addons.logDataCap }),
...( addons.createAksMetricAlerts !== defaults.addons.createAksMetricAlerts && {createAksMetricAlerts: addons.createAksMetricAlerts })
}),
...(addons.networkPolicy !== "none" && !net.ebpfDataplane && { networkPolicy: addons.networkPolicy }),
...(addons.networkPolicy !== "none" && !net.networkDataplane && { networkPolicy: addons.networkPolicy }),
...(defaults.addons.serviceMeshProfile !== addons.serviceMeshProfile && {serviceMeshProfile: addons.serviceMeshProfile }),
...(addons.azurepolicy !== "none" && { azurepolicy: addons.azurepolicy }),
...(addons.azurepolicy !== "none" && addons.azurePolicyInitiative !== defaults.addons.azurePolicyInitiative && { azurePolicyInitiative: addons.azurePolicyInitiative }),
Expand Down Expand Up @@ -160,7 +160,7 @@ export default function DeployTab({ defaults, updateFn, tabValues, invalidArray,
...(defaults.addons.blobCSIDriver !== addons.blobCSIDriver && {blobCSIDriver: addons.blobCSIDriver }),
...(defaults.addons.workloadIdentity !== addons.workloadIdentity && {oidcIssuer: true, workloadIdentity: addons.workloadIdentity }),
...(net.networkPlugin === 'azure' && {
...(net.ebpfDataplane && {ebpfDataplane: 'cilium'})
...(net.networkDataplane && {networkDataplane: 'cilium'})
}),
...(urlParams.getAll('feature').includes('defender') && cluster.DefenderForContainers !== defaults.cluster.DefenderForContainers && { DefenderForContainers: cluster.DefenderForContainers }),
...(addons.monitor === "aci" && {
Expand Down
6 changes: 3 additions & 3 deletions helper/src/components/networkTab.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,11 @@ export default function NetworkTab ({ defaults, tabValues, updateFn, invalidArra
<Checkbox
styles={{ root: { marginLeft: '50px', marginTop: '10px !important' } }}
disabled={net.networkPlugin!=='azure' || net.networkPluginMode===false}
checked={net.ebpfDataplane}
onChange={(ev, v) => updateFn("ebpfDataplane", v)}
checked={net.networkDataplane}
onChange={(ev, v) => updateFn("networkDataplane", v)}
label="Cilium powered dataplane" />
{
net.ebpfDataplane &&
net.networkDataplane &&
(
<PreviewDialog previewLink={"https://learn.microsoft.com/en-us/azure/aks/azure-cni-powered-by-cilium#prerequisites"} />
)
Expand Down
2 changes: 1 addition & 1 deletion helper/src/components/portalnav.js
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ export default function PortalNav({ config }) {
invalidFn('net', 'networkPlugin', net.networkPlugin === "kubenet" && cluster.osType === "Windows" , "Windows nodepools do not support kubenet networking")
invalidFn('net', 'cniFeatures', addons.ingress === "appgw" && net.networkPluginMode === true, "CNI Overlay does not support the Azure Application Gateway ingress controller. Please select an alternative ingress controller on the Addon Details tab")
invalidFn('addons', 'ingressControllers', addons.ingress === "appgw" && net.networkPluginMode === true, "CNI Overlay does not support the Azure Application Gateway ingress controller. Please select an alternative ingress controller to continue")
invalidFn('addons', 'networkPolicy', (!net.ebpfDataplane && addons.networkPolicy === "cilium") || (net.ebpfDataplane && (addons.networkPolicy === "calico" || addons.networkPolicy === "azure")), net.ebpfDataplane ? "Cilium epbf backplane is incompatible with Azure NPM and Calico" : "Cilium network policy requires the CNI Cilium epbf to be enabled")
invalidFn('addons', 'networkPolicy', (!net.networkDataplane && addons.networkPolicy === "cilium") || (net.networkDataplane && (addons.networkPolicy === "calico" || addons.networkPolicy === "azure")), net.networkDataplane ? "Cilium epbf backplane is incompatible with Azure NPM and Calico" : "Cilium network policy requires the CNI Cilium epbf to be enabled")
invalidFn('deploy', 'apiips', cluster.apisecurity === 'whitelist' && deploy.apiips.length < 7, 'Enter an IP/CIDR, or select \'Public IP with no IP restrictions\' in the \'Cluster API Server Security\' section of the \'Cluster Details\' tab')
invalidFn('deploy', 'clusterName', !deploy.clusterName || deploy.clusterName.match(/^[a-z0-9][_\-a-z0-9]+[a-z0-9]$/i) === null || deploy.clusterName.length > 19, 'Enter valid cluster name')

Expand Down
Loading

0 comments on commit addb445

Please sign in to comment.