Skip to content

Commit

Permalink
chore(chart): adding hooks configuration to chart (#121)
Browse files Browse the repository at this point in the history
* updating provisioner to load hook configuration from pre-defined file '/etc/nfs-provisioner'

Signed-off-by: mayank <[email protected]>
  • Loading branch information
mynktl authored Nov 11, 2021
1 parent 59d00f6 commit 913cc91
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
2 changes: 1 addition & 1 deletion deploy/helm/charts/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Helm chart for OpenEBS Dynamic NFS PV. For instructions to install
type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
version: 0.7.2
version: 0.7.3
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application.
appVersion: 0.7.1
Expand Down
1 change: 1 addition & 0 deletions deploy/helm/charts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ helm install openebs-nfs openebs-nfs/nfs-provisioner --namespace openebs --creat
| `nfsProvisioner.nfsServerNamespace` | NFS server namespace | `"openebs"` |
| `nfsProvisioner.nfsServerNodeAffinity` | NFS Server node affinity rules | `""` |
| `nfsProvisioner.nfsBackendPvcTimeout` | Timeout for backend PVC binding in seconds | `"60"` |
| `nfsProvisioner.nfsHookConfigMap` | Existing Configmap name to load hook configuration | `""` |
| `nfsStorageClass.backendStorageClass` | StorageClass to be used to provision the backend volume. If not specified, the default StorageClass is used. | `""` |
| `nfsStorageClass.isDefaultClass` | Make 'openebs-kernel-nfs' the default StorageClass | `"false"` |
| `nfsStorageClass.reclaimPolicy` | ReclaimPolicy for NFS PVs | `"Delete"` |
Expand Down
13 changes: 13 additions & 0 deletions deploy/helm/charts/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,19 @@ spec:
- test `pgrep "^provisioner-nfs.*"` = 1
initialDelaySeconds: {{ .Values.nfsProvisioner.healthCheck.initialDelaySeconds }}
periodSeconds: {{ .Values.nfsProvisioner.healthCheck.periodSeconds }}
volumeMounts:
# Mounting hook-config volume into nfs-provisioner config directory
{{- if .Values.nfsProvisioner.nfsHookConfigMap }}
- name: hook-config
mountPath: /etc/nfs-provisioner
{{- end }}
volumes:
# hook-config volume uses ConfigMap 'hook-config' to load hook configuration
{{- if .Values.nfsProvisioner.nfsHookConfigMap }}
- name: hook-config
configMap:
name: {{ .Values.nfsProvisioner.nfsHookConfigMap }}
{{- end }}
{{- if .Values.nfsProvisioner.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nfsProvisioner.nodeSelector | indent 8 }}
Expand Down
5 changes: 5 additions & 0 deletions deploy/helm/charts/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ nfsProvisioner:
# - If NFS Server needs to be placed only on storage nodes & nfs nodes then
# value can be: "kubernetes.io/storage-node,kubernetes.io/nfs-node"
# nfsServerNodeAffinity: "kubernetes.io/storage-node,kubernetes.io/nfs-node"
#
# nfsHookConfigMap represent the ConfigMap name to be used for hook configuration.
# By default, nfsHookConfigMap is set to empty.
# If nfsHookConfigMap is set then chart will mount the configmap using volume, named `hook-config`
nfsHookConfigMap: ""

nfsStorageClass:
name: openebs-kernel-nfs
Expand Down

0 comments on commit 913cc91

Please sign in to comment.