diff --git a/helm/templates/deployment.yaml b/helm/templates/deployment.yaml index f3be32a..ab25b0f 100644 --- a/helm/templates/deployment.yaml +++ b/helm/templates/deployment.yaml @@ -25,12 +25,17 @@ spec: {{- toYaml . | nindent 8 }} {{- end }} serviceAccountName: {{ include "code-marketplace.serviceAccountName" . }} - {{- if not .Values.persistence.artifactory.enabled }} + {{- if or (.Values.volumes) (not .Values.persistence.artifactory.enabled) }} volumes: + {{- if not .Values.persistence.artifactory.enabled }} - name: extensions persistentVolumeClaim: claimName: {{ include "code-marketplace.fullname" . }} {{- end }} + {{- with .Values.volumes }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- end }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: @@ -63,11 +68,16 @@ spec: - --extensions-dir - /extensions {{- end }} - {{- if not .Values.persistence.artifactory.enabled }} + {{- if or (.Values.volumeMounts) (not .Values.persistence.artifactory.enabled) }} volumeMounts: + {{- if not .Values.persistence.artifactory.enabled }} - name: extensions mountPath: /extensions {{- end }} + {{- with .Values.volumeMounts }} + {{- toYaml . | nindent 12 }} + {{- end }} + {{- end }} livenessProbe: httpGet: path: /healthz diff --git a/helm/values.yaml b/helm/values.yaml index 29bb4dd..c16cae6 100644 --- a/helm/values.yaml +++ b/helm/values.yaml @@ -77,6 +77,19 @@ autoscaling: targetCPUUtilizationPercentage: 80 # targetMemoryUtilizationPercentage: 80 +# Additional volumes on the output Deployment definition. +volumes: [] +# - name: foo +# secret: +# secretName: mysecret +# optional: false + +# Additional volumeMounts on the output Deployment definition. +volumeMounts: [] +# - name: foo +# mountPath: "/etc/foo" +# readOnly: true + nodeSelector: {} tolerations: []