diff --git a/charts/phraseanet/Chart.yaml b/charts/phraseanet/Chart.yaml index b154b4b..fa5ad18 100644 --- a/charts/phraseanet/Chart.yaml +++ b/charts/phraseanet/Chart.yaml @@ -14,7 +14,7 @@ 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.34.0 +version: 0.35.0 # This is the version number of the application being deployed. This version number should be diff --git a/charts/phraseanet/templates/cronjob_phraseanet.yaml b/charts/phraseanet/templates/cronjob_phraseanet.yaml index 9ed8792..e666544 100644 --- a/charts/phraseanet/templates/cronjob_phraseanet.yaml +++ b/charts/phraseanet/templates/cronjob_phraseanet.yaml @@ -21,24 +21,11 @@ spec: template: spec: volumes: - - name: phraseanet-config + {{- range $volume := $cronjob.volumes }} + - name: phraseanet-{{ $volume.name }} persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.config }} - - name: phraseanet-datas - persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.data }} - - name: phraseanet-thumbnails - persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.thumbnails }} - - name: phraseanet-custom - persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.custom }} - - name: phraseanet-ftp - persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.ftp }} - - name: phraseanet-backup - persistentVolumeClaim: - claimName: {{ $.Values.app.pvc_name.backup }} + claimName: phraseanet-{{ $volume.name }} + {{- end }} - name: phraseanet-tmp emptyDir: - name: phraseanet-logs @@ -56,25 +43,10 @@ spec: - -c - docker/phraseanet/worker/entrypoint.sh; export TERM=xterm; su app -c "{{ $cronjob.command }}" volumeMounts: - - name: phraseanet-config - mountPath: "/var/alchemy/Phraseanet/config" - - name: phraseanet-datas - mountPath: "/var/alchemy/Phraseanet/datas" - - name: phraseanet-tmp - mountPath: "/var/alchemy/Phraseanet/tmp" - - name: phraseanet-logs - mountPath: "/var/alchemy/Phraseanet/logs" - - name: phraseanet-thumbnails - mountPath: "/var/alchemy/Phraseanet/www/thumbnails" - - name: phraseanet-custom - mountPath: "/var/alchemy/Phraseanet/www/custom" - - name: phraseanet-cache - mountPath: "/var/alchemy/Phraseanet/cache" - - name: phraseanet-ftp - mountPath: "/var/alchemy/Phraseanet/ftp" - - name: phraseanet-backup - mountPath: "/var/alchemy/Phraseanet/backup" - + {{- range $volume := $cronjob.volumes }} + - name: phraseanet-{{ $volume.name }} + mountPath: "/var/alchemy/Phraseanet/{{ $volume.name }}" + {{- end }} env: - name: STACK_NAME value: {{ $.Values.app.stack_name | quote }} diff --git a/charts/phraseanet/values.yaml b/charts/phraseanet/values.yaml index 161829b..3700912 100644 --- a/charts/phraseanet/values.yaml +++ b/charts/phraseanet/values.yaml @@ -295,36 +295,59 @@ app: cpu: "2000m" memory: "4096Mi" cronjobs: + - id: job-0 + installed: false + name: templatejob + suspend: false + schedule: "0 0-23/2 * * *" + command: "bin/console" + volumes: + - name: config + - name: datas + - name: thumbnails + - name: custom + - name: ftp + - name: backup - id: job-1 installed: true name: validationreminder suspend: false schedule: "0 0-23/2 * * *" command: "bin/console validation:remind" + volumes: + - name: config - id: job-2 installed: false name: cleanusers suspend: true schedule: "30 3 * * 2" command: "bin/maintenance clean:user --inactivity_period 365 --grace_duration 7 --max_relances 2 --remove_basket --dry-run" + volumes: + - name: config - id: job-3 installed: false name: apilogclean suspend: false schedule: "* 5 * * 5" command: "bin/maintenance clean:ApiLogs --help" + volumes: + - name: config - id: job-4 installed: false name: workerjobclean suspend: false schedule: "* 4 * * 3" command: "bin/maintenance clean:WorkerRunningJob --help" + volumes: + - name: config - id: job-5 installed: false name: dbbackup suspend: false schedule: "* 5 * * 0-6" command: "bin/console system:backup-db -g backup/" + volumes: + - name: config replicas: fpm: scale: 1