diff --git a/charts/cluster-api-cluster-openstack/Chart.yaml b/charts/cluster-api-cluster-openstack/Chart.yaml index a2d9d75..67deeaf 100644 --- a/charts/cluster-api-cluster-openstack/Chart.yaml +++ b/charts/cluster-api-cluster-openstack/Chart.yaml @@ -2,5 +2,5 @@ apiVersion: v2 name: cluster-api-cluster-openstack description: A Helm chart to deploy a Kubernetes Cluster type: application -version: v0.5.2 +version: v0.5.3 icon: https://raw.githubusercontent.com/unikorn-cloud/helm-cluster-api/main/icons/default.png diff --git a/charts/cluster-api-cluster-openstack/README.md b/charts/cluster-api-cluster-openstack/README.md index 8d2a049..68e5c1d 100644 --- a/charts/cluster-api-cluster-openstack/README.md +++ b/charts/cluster-api-cluster-openstack/README.md @@ -36,7 +36,7 @@ spec: source: repoURL: https://unikorn-cloud.github.io/helm-cluster-api chart: cluster-api-cluster-openstack - targetRevision: v0.5.2 + targetRevision: v0.5.3 helm: releaseName: foo # Remove the default work queue. diff --git a/charts/cluster-api-cluster-openstack/templates/cluster.yaml b/charts/cluster-api-cluster-openstack/templates/cluster.yaml index 3077740..f5a9882 100644 --- a/charts/cluster-api-cluster-openstack/templates/cluster.yaml +++ b/charts/cluster-api-cluster-openstack/templates/cluster.yaml @@ -52,13 +52,16 @@ spec: {{- end }} managedSecurityGroups: allowAllInClusterTraffic: true - {{- if .Values.network.networkID }} + {{- if .Values.network.provider }} network: - id: {{ .Values.network.networkID }} - {{- end }} + id: {{ .Values.network.provider.networkID }} + subnets: + - id: {{ .Values.network.provider.subnetID }} + {{- else }} managedSubnets: - cidr: {{ .Values.network.nodeCIDR }} dnsNameservers: {{ toJson .Values.network.dnsNameservers }} + {{- end }} {{- with $net := .Values.openstack.externalNetworkID }} externalNetwork: id: {{ $net }} diff --git a/charts/cluster-api-cluster-openstack/values.schema.json b/charts/cluster-api-cluster-openstack/values.schema.json index 41d4909..7c7e21c 100644 --- a/charts/cluster-api-cluster-openstack/values.schema.json +++ b/charts/cluster-api-cluster-openstack/values.schema.json @@ -341,8 +341,20 @@ "dnsNameservers": { "$ref": "#/$defs/nonEmptyIPV4List" }, - "networkID": { - "type": "string" + "provider": { + "type": "object", + "required": [ + "networkID", + "subnetID" + ], + "properties": { + "networkID": { + "type": "string" + }, + "subnetID": { + "type": "string" + } + } } } } diff --git a/charts/cluster-api-cluster-openstack/values.yaml b/charts/cluster-api-cluster-openstack/values.yaml index 1ef8663..3298ca6 100644 --- a/charts/cluster-api-cluster-openstack/values.yaml +++ b/charts/cluster-api-cluster-openstack/values.yaml @@ -191,5 +191,8 @@ network: # If specified defines an existing nwtork to use, if not defined a network # will be created by CAPO. This allows you to use non-standard network - # types e.g. a VLAN to be used for baremetal nodes. - # networkID: 8f526b54-fab3-435d-b4b3-f65fd8474b8a + # types e.g. a VLAN to be used for baremetal nodes. The subnet must have a + # router attached. + # provider: + # networkID: 8f526b54-fab3-435d-b4b3-f65fd8474b8a + # subnetID: e3b15dd0-17e4-47c0-bc6c-1b8ea1f1018f