Skip to content

Commit

Permalink
add files-key support and fix cr
Browse files Browse the repository at this point in the history
  • Loading branch information
tuxtof committed Dec 7, 2023
1 parent fc67a71 commit 5db6fcf
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 2 deletions.
3 changes: 3 additions & 0 deletions charts/nutanix-csi-storage/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,9 @@ The following table lists the configurable parameters of the Nutanix-CSI chart a
| `filePath` | Path of the NFS share | |
| `fileServerName` | Name of the Nutanix File Server (As seen in the Prism Interface) | |
| `dynamicFileSquashType` | Squash-type for dynamic files (none, root-squash, all-squash) | `root-squash` |
| `filesKey.endpoint` | FileServer FQDN or FileServer IP (used for snapshot feature) | |
| `filesKey.username` | FileServer REST API Username (used for snapshot feature) | |
| `filesKey.password` | FileServer REST API Password (used for snapshot feature) | |
| `kubeletDir` | allows overriding the host location of kubelet's internal state | `/var/lib/kubelet` |
| `nodeSelector` | Add nodeSelector to all pods | `{}` |
| `tolerations` | Add tolerations to all pods | `[]` |
Expand Down
4 changes: 2 additions & 2 deletions charts/nutanix-csi-storage/templates/ntnx-sc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ driver: {{ include "nutanix-csi-storage.drivername" . }}
parameters:
storageType: NutanixVolumes
deletionPolicy: {{ .Values.volumeSnapshotClassRetention}}
{{- end }}
{{ end }}

{{- if eq .Values.fileClass true }}

Expand Down Expand Up @@ -79,7 +79,7 @@ parameters:
nfsPath: {{ .Values.filePath }}
allowVolumeExpansion: true
reclaimPolicy: {{ .Values.fileClassRetention }}
{{- end }}
{{ end }}

{{- if eq .Values.dynamicFileClass true }}

Expand Down
6 changes: 6 additions & 0 deletions charts/nutanix-csi-storage/templates/ntnx-secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ data:
# base64 encoded prism-ip:prism-port:admin:password.
# E.g.: echo -n "10.83.0.91:9440:admin:mypassword" | base64
key: {{ printf "%s:9440:%s:%s" .Values.prismEndPoint .Values.username .Values.password | b64enc}}
{{- if .Values.filesKey }}
{{- $filesUsername := .Values.filesKey.username | required "files username is required to create files-key." }}
{{- $filesPassword := .Values.filesKey.password | required "files password is required to create files-key." }}
{{- $filesEndPoint := .Values.filesKey.endpoint | required "files endpoint is required to create files-key." }}
files-key: {{ printf "%s:%s:%s" .Values.filesKey.endpoint .Values.filesKey.username .Values.filesKey.password | b64enc }}
{{ end }}
{{- end }}

{{- if eq .Values.createPrismCentralSecret true }}
Expand Down
6 changes: 6 additions & 0 deletions charts/nutanix-csi-storage/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,12 @@ networkSegmentation: false
# Values are: none, root-squash, all-squash. Default is root-squash
dynamicFileSquashType: root-squash

## Files key to use Snapshot feature
filesKey:
# endpoint: FileServer FQDN or FileServer IP
# username: REST API Username
# password: REST API Password

# Volume metrics and CSI operations metrics configuration
#

Expand Down

0 comments on commit 5db6fcf

Please sign in to comment.