Update snapshot-controller chart and CRDs

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
pull/590/head
Brad Davidson 2025-01-08 20:40:32 +00:00 committed by Brad Davidson
parent df00d67b98
commit 847cd3f242
12 changed files with 52 additions and 159 deletions

View File

@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/814"
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1150"
controller-gen.kubebuilder.io/version: v0.15.0
name: volumegroupsnapshotclasses.groupsnapshot.storage.k8s.io
spec:
@ -31,7 +31,7 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
name: v1alpha1
name: v1beta1
schema:
openAPIV3Schema:
description: |-

View File

@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1068"
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1150"
controller-gen.kubebuilder.io/version: v0.15.0
name: volumegroupsnapshotcontents.groupsnapshot.storage.k8s.io
spec:
@ -53,7 +53,7 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
name: v1alpha1
name: v1beta1
schema:
openAPIV3Schema:
description: |-
@ -237,8 +237,6 @@ spec:
- message: both volumeGroupSnapshotRef.name and volumeGroupSnapshotRef.namespace
must be set
rule: has(self.name) && has(self.__namespace__)
- message: volumeGroupSnapshotRef is immutable
rule: self == oldSelf
required:
- deletionPolicy
- driver
@ -257,8 +255,9 @@ spec:
The format of this field is a Unix nanoseconds time encoded as an int64.
On Unix, the command date +%s%N returns the current time in nanoseconds
since 1970-01-01 00:00:00 UTC.
format: int64
type: integer
This field is the source for the CreationTime field in VolumeGroupSnapshotStatus
format: date-time
type: string
error:
description: |-
Error is the last observed error during group snapshot creation, if any.
@ -276,42 +275,6 @@ spec:
format: date-time
type: string
type: object
pvVolumeSnapshotContentList:
description: |-
PVVolumeSnapshotContentList is the list of pairs of PV and
VolumeSnapshotContent for this group snapshot
The maximum number of allowed snapshots in the group is 100.
items:
description: |-
PVVolumeSnapshotContentPair represent a pair of PV names and
VolumeSnapshotContent names
properties:
persistentVolumeRef:
description: PersistentVolumeRef is a reference to the persistent
volume resource
properties:
name:
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
type: object
x-kubernetes-map-type: atomic
volumeSnapshotContentRef:
description: VolumeSnapshotContentRef is a reference to the
volume snapshot content resource
properties:
name:
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
type: object
x-kubernetes-map-type: atomic
type: object
type: array
readyToUse:
description: |-
ReadyToUse indicates if all the individual snapshots in the group are ready to be
@ -325,6 +288,32 @@ spec:
If a storage system does not provide such an id, the
CSI driver can choose to return the VolumeGroupSnapshot name.
type: string
volumeSnapshotHandlePairList:
description: |-
VolumeSnapshotHandlePairList is a list of CSI "volume_id" and "snapshot_id"
pair returned by the CSI driver to identify snapshots and their source volumes
on the storage system.
items:
description: VolumeSnapshotHandlePair defines a pair of a source
volume handle and a snapshot handle
properties:
snapshotHandle:
description: |-
SnapshotHandle is a unique id returned by the CSI driver to identify a volume
snapshot on the storage system
Required.
type: string
volumeHandle:
description: |-
VolumeHandle is a unique id returned by the CSI driver to identify a volume
on the storage system
Required.
type: string
required:
- snapshotHandle
- volumeHandle
type: object
type: array
type: object
required:
- spec

View File

@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1068"
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1150"
controller-gen.kubebuilder.io/version: v0.15.0
name: volumegroupsnapshots.groupsnapshot.storage.k8s.io
spec:
@ -43,7 +43,7 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
name: v1alpha1
name: v1beta1
schema:
openAPIV3Schema:
description: |-
@ -198,6 +198,7 @@ spec:
The format of this field is a Unix nanoseconds time encoded as an int64.
On Unix, the command date +%s%N returns the current time in nanoseconds
since 1970-01-01 00:00:00 UTC.
This field is updated based on the CreationTime field in VolumeGroupSnapshotContentStatus
format: date-time
type: string
error:
@ -221,41 +222,6 @@ spec:
format: date-time
type: string
type: object
pvcVolumeSnapshotRefList:
description: |-
VolumeSnapshotRefList is the list of PVC and VolumeSnapshot pairs that
is part of this group snapshot.
The maximum number of allowed snapshots in the group is 100.
items:
description: PVCVolumeSnapshotPair defines a pair of a PVC reference
and a Volume Snapshot Reference
properties:
persistentVolumeClaimRef:
description: PersistentVolumeClaimRef is a reference to the
PVC this pair is referring to
properties:
name:
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
type: object
x-kubernetes-map-type: atomic
volumeSnapshotRef:
description: VolumeSnapshotRef is a reference to the VolumeSnapshot
this pair is referring to
properties:
name:
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
type: object
x-kubernetes-map-type: atomic
type: object
type: array
readyToUse:
description: |-
ReadyToUse indicates if all the individual snapshots in the group are ready

View File

@ -132,7 +132,7 @@ spec:
- deletionPolicy
- driver
type: object
served: true
served: false
storage: false
subresources: {}
status:

View File

@ -445,7 +445,7 @@ spec:
required:
- spec
type: object
served: true
served: false
storage: false
subresources:
status: {}

View File

@ -339,7 +339,7 @@ spec:
required:
- spec
type: object
served: true
served: false
storage: false
subresources:
status: {}

View File

@ -5,6 +5,6 @@
type: application
-name: snapshot-controller
+name: rke2-snapshot-controller
version: 3.0.6
appVersion: "v8.1.0"
version: 4.0.0
appVersion: "v8.2.0"
kubeVersion: ">= 1.25.0-0"

View File

@ -1,9 +1,9 @@
--- charts-original/templates/_helpers.tpl
+++ charts/templates/_helpers.tpl
@@ -132,3 +132,11 @@
{{- include "snapshot-validation-webhook.fullname" . }}-tls
{{- end }}
{{- end }}
@@ -59,3 +59,11 @@
{{ default "default" .Values.controller.serviceAccount.name }}
{{- end -}}
{{- end -}}
+
+{{- define "system_default_registry" -}}
+{{- if .Values.global.systemDefaultRegistry -}}

View File

@ -1,11 +0,0 @@
--- charts-original/templates/deployment_validation_webhook.yaml
+++ charts/templates/deployment_validation_webhook.yaml
@@ -37,7 +37,7 @@
- name: {{ include "snapshot-validation-webhook.name" . }}
securityContext:
{{- toYaml .Values.webhook.securityContext | nindent 12 }}
- image: "{{ .Values.webhook.image.repository }}:{{ .Values.webhook.image.tag | default .Chart.AppVersion }}"
+ image: "{{ template "system_default_registry" . }}{{ .Values.webhook.image.repository }}:{{ .Values.webhook.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.webhook.image.pullPolicy }}
args:
{{- range $flag, $val := .Values.webhook.args }}

View File

@ -5,7 +5,7 @@
image:
- repository: registry.k8s.io/sig-storage/snapshot-controller
+ repository: rancher/mirrored-sig-storage-snapshot-controller
+ repository: rancher/mirrored-sig-storage-snapshot-validation-webhook
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: ""
@ -28,61 +28,10 @@
affinity: {}
@@ -82,7 +89,7 @@
@@ -80,3 +87,6 @@
# DNS Policy for controller pod. For Pods running with hostNetwork, set to `ClusterFirstWithHostNet`
# For further reference: https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy.
dnsPolicy: ClusterFirst
webhook:
- enabled: true
+ enabled: false
replicaCount: 1
@@ -95,7 +102,7 @@
# enableVolumeGroupSnapshotWebhook: true
image:
- repository: registry.k8s.io/sig-storage/snapshot-validation-webhook
+ repository: rancher/mirrored-sig-storage-snapshot-validation-webhook
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: ""
@@ -150,9 +157,16 @@
resources: {}
- nodeSelector: {}
+ nodeSelector:
+ kubernetes.io/os: linux
- tolerations: []
+ tolerations:
+ - key: "node-role.kubernetes.io/control-plane"
+ operator: "Exists"
+ effect: "NoSchedule"
+ - key: "node-role.kubernetes.io/etcd"
+ operator: "Exists"
+ effect: "NoExecute"
affinity: {}
@@ -173,8 +187,18 @@
dnsPolicy: ClusterFirst
tests:
- nodeSelector: { }
+ nodeSelector:
+ kubernetes.io/os: linux
- tolerations: [ ]
+ tolerations:
+ - key: "node-role.kubernetes.io/control-plane"
+ operator: "Exists"
+ effect: "NoSchedule"
+ - key: "node-role.kubernetes.io/etcd"
+ operator: "Exists"
+ effect: "NoExecute"
affinity: { }
+
+global:
+ systemDefaultRegistry: ""

View File

@ -1,6 +1,6 @@
url: https://github.com/piraeusdatastore/helm-charts.git
subdirectory: charts/snapshot-controller
commit: 79c15f2317860baf58fa70d00ff355a631a77206 # snapshot-controller-3.0.6
commit: caf8780858bdd5afe1d80fe2f559ca138f29740e # snapshot-controller-4.0.0
packageVersion: 01
additionalCharts:
- workingDir: charts-crd

View File

@ -1,6 +1,6 @@
apiVersion: v1
version: 3.0.6
appVersion: "v8.1.0"
version: 4.0.0
appVersion: "v8.2.0"
description: Installs the CRDs for rke2-snapshot-controller
name: rke2-snapshot-controller-crd
type: application