diff --git a/charts/nextcloud/Chart.yaml b/charts/nextcloud/Chart.yaml index ee759ca1..6d5c5bac 100644 --- a/charts/nextcloud/Chart.yaml +++ b/charts/nextcloud/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: nextcloud -version: 9.4.0 +version: 9.4.1 # renovate: image=docker.io/library/nextcloud appVersion: 35.0.1 description: A file sharing server that puts the control and security of your own data back into your hands. diff --git a/charts/nextcloud/templates/deployment.yaml b/charts/nextcloud/templates/deployment.yaml index ab2ddc3e..272e55c5 100644 --- a/charts/nextcloud/templates/deployment.yaml +++ b/charts/nextcloud/templates/deployment.yaml @@ -85,6 +85,11 @@ spec: readOnly: true {{- end }} {{- end }} + {{- if or $.Values.redis.enabled $.Values.externalRedis.enabled }} + - name: php-confd + mountPath: "/usr/local/etc/php/conf.d/redis-session.ini" # fix permission denied error + subPath: redis-session.ini + {{- end }} {{- if not .Values.nginx.enabled }} ports: - name: http @@ -271,11 +276,6 @@ spec: {{- toYaml . | nindent 12 }} {{- end }} volumeMounts: - {{- if $.Values.redis.enabled }} - - name: php-confd - mountPath: "/usr/local/etc/php/conf.d/redis-session.ini" # fix permission denied error - subPath: redis-session.ini - {{- end }} {{- include "nextcloud.volumeMounts" $ | trim | nindent 12 }} {{- end }} {{- end }}{{/* end-if cronjob.enabled */}} @@ -289,7 +289,7 @@ spec: {{- with $.Values.nextcloud.priorityClassName | default $.Values.priorityClassName }} priorityClassName: {{ . }} {{- end }} - {{- if or .Values.nextcloud.extraInitContainers .Values.mariadb.enabled .Values.postgresql.enabled .Values.redis.enabled }} + {{- if or .Values.nextcloud.extraInitContainers .Values.mariadb.enabled .Values.postgresql.enabled .Values.redis.enabled .Values.externalRedis.enabled }} initContainers: {{- with .Values.nextcloud.extraInitContainers }} {{- toYaml . | nindent 8 }} @@ -325,7 +325,7 @@ spec: - "-c" - "until pg_isready -h ${POSTGRES_HOST} -U ${POSTGRES_USER} ; do sleep 2 ; done" {{- end }}{{/* end-if any database-initContainer */}} - {{- if .Values.redis.enabled }} + {{- if or $.Values.redis.enabled $.Values.externalRedis.enabled }} # create empty redis file for nextcloud entrypoint to override it - name: init-redis-session-ini # Using the same image as nextcloud to get the same UID to write the configuration. @@ -403,7 +403,7 @@ spec: name: {{ template "nextcloud.fullname" . }}-hooks defaultMode: 0o755 {{- end }} - {{- if .Values.redis.enabled }} + {{- if or $.Values.redis.enabled $.Values.externalRedis.enabled }} - name: php-confd emptyDir: {} {{- end }} diff --git a/charts/nextcloud/values.yaml b/charts/nextcloud/values.yaml index 860ad7ad..059a18b5 100644 --- a/charts/nextcloud/values.yaml +++ b/charts/nextcloud/values.yaml @@ -381,9 +381,9 @@ nextcloud: # Set postgresql initContainer securityContext parameters. For example, you may need to define runAsNonRoot directive securityContext: {} - # Settings for the Redis init container that creates a configuration file to address permission issue in some cluster - redisInitContainer: - resources: {} + # Settings for the Redis init container that creates a configuration file to address permission issue in some cluster + redisInitContainer: + resources: {} # -- priority class for nextcloud. # Overrides .Values.priorityClassName