Skip to content
This repository has been archived by the owner on Oct 10, 2023. It is now read-only.

'ACT_main' json patch fails with multiple VNET cidr blocks #4621

Open
PierrePIRONIN opened this issue May 25, 2023 · 1 comment
Open

'ACT_main' json patch fails with multiple VNET cidr blocks #4621

PierrePIRONIN opened this issue May 25, 2023 · 1 comment
Labels
kind/bug PR/Issue related to a bug needs-triage Indicates an issue or PR needs to be triaged

Comments

@PierrePIRONIN
Copy link

Bug description
Using the Azure Cluster Class to deploy an Azure Kubernetes cluster, the 'ACT_main' json patch fails when multiple VNET cidr blocks are provided.
This is due to a go templating typo, hyphen that should not be present at the end of a range loop on network.vnet.cidrBlocks (see PR I’ve opened to fix it).

Affected product area (please put an X in all that apply)

  • (X) APIs
  • ( ) Addons
  • ( ) CLI
  • ( ) Docs
  • ( ) IAM
  • ( ) Installation
  • ( ) Plugin
  • ( ) Security
  • ( ) Test and Release
  • ( ) User Experience
  • ( ) Developer Experience

Expected behavior
Valid template rendering when multiple VNET cidr blocks are provided.

Steps to reproduce the bug
Try to build an Azure Kubernetes cluster with multiple VNET cidr blocks.

Version (include the SHA if the version is not obvious)
At least TKG 2.2.0 and TKG 2.1.1 which were the ones I’ve tested.

Environment where the bug was observed (cloud, OS, etc)
Azure

Relevant Debug Output (Logs, manifests, etc)
Logs extracted from capi-controller :

E0525 14:28:24.579774 1 controller.go:326] "Reconciler error" err="error reconciling the Cluster topology: failed to create AzureCluster.infrastructure.cluster.x-k8s.io: FieldValueInvalid: spec.networkSpec.cidrBlocks: Invalid value: "10.221.98.192/27- 10.221.98.224/27": invalid CIDR format FieldValueInvalid: spec.networkSpec.subnets[0].cidrBlocks: Invalid value: "10.221.98.192/27": subnet CIDR not in vnet address space: [10.221.98.192/27- 10.221.98.224/27] FieldValueInvalid: spec.networkSpec.subnets[1].cidrBlocks: Invalid value: "10.221.98.224/27": subnet CIDR not in vnet address space: [10.221.98.192/27- 10.221.98.224/27]" controller="topology/cluster" controllerGroup="cluster.x-k8s.io" controllerKind="Cluster" cluster="k8s-mma/k8s-mma" namespace="k8s-mma" name="k8s-mma" reconcileID=eea64084-273f-4028-9b70-374514886761

@PierrePIRONIN PierrePIRONIN added kind/bug PR/Issue related to a bug needs-triage Indicates an issue or PR needs to be triaged labels May 25, 2023
@github-actions
Copy link

Hey @PierrePIRONIN! Thanks for opening your first issue. We appreciate your contribution and welcome you to our community! We are glad to have you here and to have your input on Tanzu Framework.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug PR/Issue related to a bug needs-triage Indicates an issue or PR needs to be triaged
Projects
None yet
Development

No branches or pull requests

1 participant