Skip to content

Commit

Permalink
Update for helm charts cephfs-canary
Browse files Browse the repository at this point in the history
  • Loading branch information
ceph-csi-bot committed Dec 12, 2024
1 parent 6ae3780 commit e5f21f3
Show file tree
Hide file tree
Showing 13 changed files with 378 additions and 144 deletions.
Binary file modified docs/cephfs/ceph-csi-cephfs-3-canary.tgz
Binary file not shown.
8 changes: 4 additions & 4 deletions docs/cephfs/ceph-csi-cephfs/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
apiVersion: v1
appVersion: 3.12-canary
appVersion: canary
description: "Container Storage Interface (CSI) driver,
provisioner, snapshotter and resizer for Ceph cephfs"
name: ceph-csi-cephfs
version: 3.12-canary
version: 3-canary
keywords:
- ceph
- cephfs
- ceph-csi
home: https://github.com/ceph/ceph-csi
sources:
- https://github.com/ceph/ceph-csi/tree/release-v3.12/charts/ceph-csi-cephfs
icon: https://raw.githubusercontent.com/ceph/ceph-csi/release-v3.12/assets/ceph-logo.png
- https://github.com/ceph/ceph-csi/tree/devel/charts/ceph-csi-cephfs
icon: https://raw.githubusercontent.com/ceph/ceph-csi/devel/assets/ceph-logo.png
57 changes: 49 additions & 8 deletions docs/cephfs/ceph-csi-cephfs/README.md

Large diffs are not rendered by default.

15 changes: 15 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/encryptionkms-configmap.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Values.kmsConfigMapName | quote }}
namespace: {{ .Release.Namespace }}
labels:
app: {{ include "ceph-csi-cephfs.name" . }}
chart: {{ include "ceph-csi-cephfs.chart" . }}
component: {{ .Values.nodeplugin.name }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
data:
config.json: |-
{{ toJson .Values.encryptionKMSConfig | indent 4 -}}
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,14 @@ rules:
- apiGroups: [""]
resources: ["nodes"]
verbs: ["get"]
# allow to read Vault Token and connection options from the Tenants namespace
- apiGroups: [""]
resources: ["configmaps"]
verbs: ["get"]
{{- if and .Values.encryptionKMSConfig .Values.encryptionKMSConfig.secretNamespace (not .Values.rbac.leastPrivileges) }}
# allow to read the encryption key used with the metadata KMS
- apiGroups: [""]
resources: ["secrets"]
verbs: ["get"]
{{- end -}}
{{- end -}}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ metadata:
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
{{- if .Values.nodeplugin.annotations }}
annotations:
{{- toYaml .Values.nodeplugin.annotations | nindent 4 -}}
{{- end }}
spec:
selector:
matchLabels:
Expand All @@ -27,6 +31,10 @@ spec:
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 8 }}{{- end }}
{{- if .Values.nodeplugin.podAnnotations }}
annotations:
{{- toYaml .Values.nodeplugin.podAnnotations | nindent 8 -}}
{{- end }}
spec:
securityContext: {{ toYaml .Values.nodeplugin.podSecurityContext | nindent 8 }}
serviceAccountName: {{ include "ceph-csi-cephfs.serviceAccountName.nodeplugin" . }}
Expand Down Expand Up @@ -72,6 +80,7 @@ spec:
{{- if and .Values.readAffinity .Values.readAffinity.enabled }}
- "--crush-location-labels={{ .Values.readAffinity.crushLocationLabels | join "," }}"
{{- end }}
- "--logslowopinterval={{ .Values.logSlowOperationInterval }}"
env:
- name: POD_IP
valueFrom:
Expand Down
22 changes: 22 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/nodeplugin-role.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{{- if and .Values.rbac.create .Values.rbac.leastPrivileges -}}
{{- if and .Values.encryptionKMSConfig (eq .Values.encryptionKMSConfig.encryptionKMSType "metadata") .Values.encryptionKMSConfig.secretNamespace .Values.encryptionKMSConfig.secretName -}}
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: {{ include "ceph-csi-cephfs.nodeplugin.fullname" . }}
namespace: {{ .Values.encryptionKMSConfig.secretNamespace }}
labels:
app: {{ include "ceph-csi-cephfs.name" . }}
chart: {{ include "ceph-csi-cephfs.chart" . }}
component: {{ .Values.nodeplugin.name }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
rules:
# allow to read the encryption key used with the metadata KMS
- apiGroups: [""]
resources: ["secrets"]
verbs: ["get"]
resourceNames: [{{ .Values.encryptionKMSConfig.secretName | quote }}]
{{- end -}}
{{- end -}}
24 changes: 24 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/nodeplugin-rolebinding.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{{- if and .Values.rbac.create .Values.rbac.leastPrivileges -}}
{{- if and .Values.encryptionKMSConfig (eq .Values.encryptionKMSConfig.encryptionKMSType "metadata") .Values.encryptionKMSConfig.secretNamespace -}}
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: {{ include "ceph-csi-cephfs.nodeplugin.fullname" . }}
namespace: {{ .Values.encryptionKMSConfig.secretNamespace }}
labels:
app: {{ include "ceph-csi-cephfs.name" . }}
chart: {{ include "ceph-csi-cephfs.chart" . }}
component: {{ .Values.nodeplugin.name }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
subjects:
- kind: ServiceAccount
name: {{ include "ceph-csi-cephfs.serviceAccountName.nodeplugin" . }}
namespace: {{ .Release.Namespace }}
roleRef:
kind: Role
name: {{ include "ceph-csi-cephfs.nodeplugin.fullname" . }}
apiGroup: rbac.authorization.k8s.io
{{- end -}}
{{- end -}}
48 changes: 48 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/provisioner-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ metadata:
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
{{- if .Values.provisioner.annotations }}
annotations:
{{- toYaml .Values.provisioner.annotations | nindent 4 -}}
{{- end }}
spec:
replicas: {{ .Values.provisioner.replicaCount }}
strategy:
Expand All @@ -32,6 +36,10 @@ spec:
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 8 }}{{- end }}
{{- if .Values.provisioner.podAnnotations }}
annotations:
{{- toYaml .Values.provisioner.podAnnotations | nindent 8 -}}
{{- end }}
spec:
{{- if gt (int .Values.provisioner.replicaCount) 1 }}
affinity:
Expand Down Expand Up @@ -92,6 +100,7 @@ spec:
- "--clustername={{ .Values.provisioner.clustername }}"
{{- end }}
- "--setmetadata={{ .Values.provisioner.setmetadata }}"
- "--logslowopinterval={{ .Values.logSlowOperationInterval }}"
env:
- name: POD_IP
valueFrom:
Expand Down Expand Up @@ -135,12 +144,25 @@ spec:
- "--extra-create-metadata=true"
- "--feature-gates=HonorPVReclaimPolicy=true"
- "--prevent-volume-mode-conversion=true"
{{- if and .Values.provisioner.provisioner.args .Values.provisioner.provisioner.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.provisioner.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.provisioner.extraArgs }}
- "--{{ . }}"
{{- end }}
env:
- name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.provisioner.args .Values.provisioner.provisioner.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.provisioner.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts:
- name: socket-dir
mountPath: /csi
Expand All @@ -156,12 +178,25 @@ spec:
- "--leader-election=true"
- "--extra-create-metadata=true"
- "--enable-volume-group-snapshots={{.Values.provisioner.snapshotter.args.enableVolumeGroupSnapshots }}"
{{- if and .Values.provisioner.snapshotter.args .Values.provisioner.snapshotter.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.snapshotter.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.snapshotter.extraArgs }}
- "--{{ . }}"
{{- end }}
env:
- name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.snapshotter.args .Values.provisioner.snapshotter.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.snapshotter.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts:
- name: socket-dir
mountPath: /csi
Expand All @@ -179,12 +214,25 @@ spec:
- "--retry-interval-start=500ms"
- "--handle-volume-inuse-error=false"
- "--feature-gates=RecoverVolumeExpansionFailure=true"
{{- if and .Values.provisioner.resizer.args .Values.provisioner.resizer.args.httpEndpointPort }}
- "--http-endpoint=$(POD_IP):{{ .Values.provisioner.resizer.args.httpEndpointPort }}"
{{- end }}
{{- range .Values.provisioner.resizer.extraArgs }}
- "--{{ . }}"
{{- end }}
env:
- name: ADDRESS
value: "unix:///csi/{{ .Values.provisionerSocketFile }}"
{{- if and .Values.provisioner.resizer.args .Values.provisioner.resizer.args.httpEndpointPort }}
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- containerPort: {{ .Values.provisioner.resizer.args.httpEndpointPort }}
name: http-endpoint
protocol: TCP
{{- end }}
volumeMounts:
- name: socket-dir
mountPath: /csi
Expand Down
6 changes: 6 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ metadata:
heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
stringData:
{{- if .Values.secret.userID }}
userID: {{ .Values.secret.userID }}
{{- end }}
{{- if .Values.secret.userKey }}
userKey: {{ .Values.secret.userKey }}
{{- end }}
adminID: {{ .Values.secret.adminID }}
adminKey: {{ .Values.secret.adminKey }}
{{- end -}}
6 changes: 6 additions & 0 deletions docs/cephfs/ceph-csi-cephfs/templates/storageclass.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@ parameters:
{{- if .Values.storageClass.pool }}
pool: {{ .Values.storageClass.pool }}
{{- end }}
{{- if .Values.storageClass.encrypted }}
encrypted: "{{ .Values.storageClass.encrypted }}"
{{- end }}
{{- if .Values.storageClass.encryptionKMSID }}
encryptionKMSID: {{ .Values.storageClass.encryptionKMSID }}
{{- end }}
{{- if .Values.storageClass.fuseMountOptions }}
fuseMountOptions: "{{ .Values.storageClass.fuseMountOptions }}"
{{- end }}
Expand Down
Loading

0 comments on commit e5f21f3

Please sign in to comment.