Skip to content

Commit

Permalink
Use IDs for Images (#7)
Browse files Browse the repository at this point in the history
Much more precise, plus everything else uses ID now.
  • Loading branch information
spjmurray authored Jun 10, 2024
1 parent 4c52c19 commit a6116fc
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 15 deletions.
2 changes: 1 addition & 1 deletion charts/cluster-api-cluster-openstack/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ apiVersion: v2
name: cluster-api-cluster-openstack
description: A Helm chart to deploy a Kubernetes Cluster
type: application
version: v0.4.1
version: v0.4.2
icon: https://raw.githubusercontent.com/unikorn-cloud/helm-cluster-api/main/icons/default.png
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,9 @@ metadata:
spec:
template:
spec:
flavor: {{ .Values.controlPlane.machine.flavor }}
flavor: {{ .Values.controlPlane.machine.flavorID }}
image:
filter:
name: {{ .Values.controlPlane.machine.image }}
id: {{ .Values.controlPlane.machine.imageID }}
{{- if .Values.openstack.sshKeyName }}
sshKeyName: {{ .Values.openstack.sshKeyName }}
{{- end }}
Expand Down
5 changes: 2 additions & 3 deletions charts/cluster-api-cluster-openstack/templates/workload.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,9 @@ spec:
identityRef:
name: {{ include "cloudconfig.name" $ }}
cloudName: {{ $.Values.openstack.cloud }}
flavor: {{ $pool.machine.flavor }}
flavor: {{ $pool.machine.flavorID }}
image:
filter:
name: {{ $pool.machine.image }}
id: {{ $pool.machine.imageID }}
{{- if $.Values.openstack.sshKeyName }}
sshKeyName: {{ $.Values.openstack.sshKeyName }}
{{- end }}
Expand Down
8 changes: 4 additions & 4 deletions charts/cluster-api-cluster-openstack/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -101,14 +101,14 @@
"machine": {
"type": "object",
"required": [
"image",
"flavor"
"imageID",
"flavorID"
],
"properties": {
"image": {
"imageID": {
"type": "string"
},
"flavor": {
"flavorID": {
"type": "string"
},
"disk": {
Expand Down
8 changes: 4 additions & 4 deletions charts/cluster-api-cluster-openstack/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@ controlPlane:
# Modifications to this object will trigger a control plane upgrade.
machine:
# Openstack image name.
image: ubuntu-2204-kubernetes-1.25.0
imageID: f810a963-437d-4a24-a972-a0bff942542b

# Control plane machine type.
flavor: m1.large
flavorID: 6ac45c49-3e3b-4cdf-acbc-d98a321a92c0

# Ephemeral disk size in GiB. If specified this overrides the default
# size for the flavor.
Expand All @@ -108,10 +108,10 @@ controlPlane:
# # Modifications to these objects will trigger a affected workload pool upgrades.
# machine:
# # Openstack image name.
# image: ubuntu-2204-kubernetes-1.25.0
# imageID: f810a963-437d-4a24-a972-a0bff942542b
#
# # Workload machine type.
# flavor: m1.large
# flavorID: 6ac45c49-3e3b-4cdf-acbc-d98a321a92c0
#
# # Ephemeral disk size in GiB. If specified this overrides the default
# # size for the flavor.
Expand Down

0 comments on commit a6116fc

Please sign in to comment.