Parcourir la source

Publish new changes in catalog

sonicaj il y a 2 ans
Parent
commit
0338bd5d13
29 fichiers modifiés avec 34 ajouts et 40 suppressions
  1. 0 15
      charts/nextcloud/1.6.46/templates/backup-postgres-config.yaml
  2. 0 24
      charts/nextcloud/1.6.46/templates/nuke-deployments-hook.yaml
  3. 0 0
      charts/nextcloud/1.6.47/.helmignore
  4. 0 0
      charts/nextcloud/1.6.47/Chart.lock
  5. 1 1
      charts/nextcloud/1.6.47/Chart.yaml
  6. 0 0
      charts/nextcloud/1.6.47/README.md
  7. 0 0
      charts/nextcloud/1.6.47/app-readme.md
  8. 0 0
      charts/nextcloud/1.6.47/charts/common-2304.0.1.tgz
  9. 0 0
      charts/nextcloud/1.6.47/ci/test-values.yaml
  10. 0 0
      charts/nextcloud/1.6.47/ix_values.yaml
  11. 0 0
      charts/nextcloud/1.6.47/metadata.yaml
  12. 0 0
      charts/nextcloud/1.6.47/migrations/migrate_from_1.1.0
  13. 0 0
      charts/nextcloud/1.6.47/questions.yaml
  14. 0 0
      charts/nextcloud/1.6.47/templates/NOTES.txt
  15. 0 0
      charts/nextcloud/1.6.47/templates/_nginx.tpl
  16. 0 0
      charts/nextcloud/1.6.47/templates/_postgres.tpl
  17. 24 0
      charts/nextcloud/1.6.47/templates/backup-postgres-config.yaml
  18. 9 0
      charts/nextcloud/1.6.47/templates/backup-postgres-hook.yaml
  19. 0 0
      charts/nextcloud/1.6.47/templates/cronjob.yaml
  20. 0 0
      charts/nextcloud/1.6.47/templates/deployment.yaml
  21. 0 0
      charts/nextcloud/1.6.47/templates/nextcloud-configmap.yaml
  22. 0 0
      charts/nextcloud/1.6.47/templates/nginx-configmap.yaml
  23. 0 0
      charts/nextcloud/1.6.47/templates/nginx-secret.yaml
  24. 0 0
      charts/nextcloud/1.6.47/templates/postgres-deployment.yaml
  25. 0 0
      charts/nextcloud/1.6.47/templates/postgres-secret.yaml
  26. 0 0
      charts/nextcloud/1.6.47/templates/postgres-service.yaml
  27. 0 0
      charts/nextcloud/1.6.47/templates/secrets.yaml
  28. 0 0
      charts/nextcloud/1.6.47/templates/service.yaml
  29. 0 0
      charts/nextcloud/1.6.47/templates/serviceaccount.yaml

+ 0 - 15
charts/nextcloud/1.6.46/templates/backup-postgres-config.yaml

@@ -1,15 +0,0 @@
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: "postgres-backup-hook-config-map"
-  annotations:
-    rollme: {{ randAlphaNum 5 | quote }}
-data:
-  entrypoint.sh: |-
-    #!/bin/sh
-    cmd="/docker-entrypoint.sh postgres"
-    eval "${cmd}" & disown;
-    until pg_isready; do
-      sleep 5;
-    done;
-    pg_dump -U $POSTGRES_USER -d {{ template "postgres.DatabaseName" . }} > /postgres_backups/$BACKUP_NAME;

+ 0 - 24
charts/nextcloud/1.6.46/templates/nuke-deployments-hook.yaml

@@ -1,24 +0,0 @@
-{{- if .Values.ixChartContext.isUpgrade -}}
-{{ $values := (. | mustDeepCopy) }}
-{{ $_ := set $values "common" (dict "nameSuffix" "postgres") }}
-apiVersion: batch/v1
-kind: Job
-metadata:
-  name: "pre-upgrade-hook1"
-  annotations:
-    "helm.sh/hook": pre-upgrade
-    "helm.sh/hook-weight": "-1"
-    "helm.sh/hook-delete-policy": hook-succeeded
-    rollme: {{ randAlphaNum 5 | quote }}
-spec:
-  template:
-    metadata:
-      name: "pre-upgrade-hook1"
-    spec:
-      restartPolicy: Never
-      serviceAccountName: "{{ template "common.names.serviceAccountName" . }}"
-      containers:
-      - name: kubectl
-        image: "bitnami/kubectl:1.19"
-        command: ["kubectl", "delete" , "deployment", "{{ template "common.names.fullname" . }}", "{{ template "common.names.fullname" $values }}"]
-{{- end -}}

+ 0 - 0
charts/nextcloud/1.6.46/.helmignore → charts/nextcloud/1.6.47/.helmignore


+ 0 - 0
charts/nextcloud/1.6.46/Chart.lock → charts/nextcloud/1.6.47/Chart.lock


+ 1 - 1
charts/nextcloud/1.6.46/Chart.yaml → charts/nextcloud/1.6.47/Chart.yaml

@@ -4,7 +4,7 @@ description: A file sharing server that puts the control and security of your ow
 annotations:
   title: Nextcloud
 type: application
-version: 1.6.46
+version: 1.6.47
 apiVersion: v2
 appVersion: 27.0.2
 kubeVersion: '>=1.16.0-0'

+ 0 - 0
charts/nextcloud/1.6.46/README.md → charts/nextcloud/1.6.47/README.md


+ 0 - 0
charts/nextcloud/1.6.46/app-readme.md → charts/nextcloud/1.6.47/app-readme.md


+ 0 - 0
charts/nextcloud/1.6.46/charts/common-2304.0.1.tgz → charts/nextcloud/1.6.47/charts/common-2304.0.1.tgz


+ 0 - 0
charts/nextcloud/1.6.46/ci/test-values.yaml → charts/nextcloud/1.6.47/ci/test-values.yaml


+ 0 - 0
charts/nextcloud/1.6.46/ix_values.yaml → charts/nextcloud/1.6.47/ix_values.yaml


+ 0 - 0
charts/nextcloud/1.6.46/metadata.yaml → charts/nextcloud/1.6.47/metadata.yaml


+ 0 - 0
charts/nextcloud/1.6.46/migrations/migrate_from_1.1.0 → charts/nextcloud/1.6.47/migrations/migrate_from_1.1.0


+ 0 - 0
charts/nextcloud/1.6.46/questions.yaml → charts/nextcloud/1.6.47/questions.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/NOTES.txt → charts/nextcloud/1.6.47/templates/NOTES.txt


+ 0 - 0
charts/nextcloud/1.6.46/templates/_nginx.tpl → charts/nextcloud/1.6.47/templates/_nginx.tpl


+ 0 - 0
charts/nextcloud/1.6.46/templates/_postgres.tpl → charts/nextcloud/1.6.47/templates/_postgres.tpl


+ 24 - 0
charts/nextcloud/1.6.47/templates/backup-postgres-config.yaml

@@ -0,0 +1,24 @@
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: "postgres-backup-hook-config-map"
+  annotations:
+    rollme: {{ randAlphaNum 5 | quote }}
+data:
+  entrypoint.sh: |-
+    #!/bin/bash
+    echo "Fetching password from config.php"
+
+    # sed removes ' , => spaces and db* from the string
+    DBUSER=$(cat /nc-config/config.php | grep "dbuser" | sed "s/dbuser\| \|'\|,\|=>//g")
+    DBPASS=$(cat /nc-config/config.php | grep "dbpassword" | sed "s/dbpassword\| \|'\|,\|=>//g")
+    DBNAME=$(cat /nc-config/config.php | grep "dbname" | sed "s/dbname\| \|'\|,\|=>//g")
+    [ -n "$DBUSER" ] && [ -n "$DBPASS" ] && [ -n "$DBNAME" ] && echo "User, Database and password fetched from config.php"
+
+    until pg_isready -U ${POSTGRES_USER} -h ${POSTGRES_HOST}; do sleep 2; done
+
+    # pg_dump will automatically use the password from the PGPASSWORD environment variable
+    echo "Creating backup of ${DBNAME} database as ${DBUSER}"
+    PGPASSWORD=${DBPASS} pg_dump -U $DBUSER -d $DBNAME --host=${POSTGRES_HOST} > /postgres_backups/$BACKUP_NAME \
+      && echo "Backup created successfully" \
+      || echo "Backup failed"

+ 9 - 0
charts/nextcloud/1.6.46/templates/backup-postgres-hook.yaml → charts/nextcloud/1.6.47/templates/backup-postgres-hook.yaml

@@ -1,6 +1,7 @@
 {{- if .Values.ixChartContext.isUpgrade -}}
 {{ $values := (. | mustDeepCopy) }}
 {{ $_ := set $values "common" (dict "nameSuffix" "postgres") }}
+{{ $dbHost := .Values.nextcloudDbHost }}
 apiVersion: batch/v1
 kind: Job
 metadata:
@@ -24,11 +25,16 @@ spec:
         env: {{ include "postgres.envVariableConfiguration" $values | nindent 10 }}
           - name: BACKUP_NAME
             value: {{ template "postgres.backupName" . }}
+          - name: POSTGRES_HOST
+            value: {{ $dbHost }}
         volumeMounts: {{ include "postgres.volumeMountsConfiguration" $values | nindent 10 }}
           - name: backup-script-configmap
             mountPath: /bin/backup_entrypoint.sh
             readOnly: true
             subPath: entrypoint.sh
+          - name: nextcloud-data
+            mountPath: /nc-config
+            subPath: "config"
         command:
           - "/bin/backup_entrypoint.sh"
       volumes: {{ include "postgres.volumeConfiguration" $values | nindent 8 }}
@@ -36,4 +42,7 @@ spec:
           configMap:
             defaultMode: 0700
             name: "postgres-backup-hook-config-map"
+        {{ if .Values.appVolumeMounts }}
+        {{- include "common.storage.configureAppVolumes" .Values | nindent 8 }}
+        {{ end }}
 {{- end -}}

+ 0 - 0
charts/nextcloud/1.6.46/templates/cronjob.yaml → charts/nextcloud/1.6.47/templates/cronjob.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/deployment.yaml → charts/nextcloud/1.6.47/templates/deployment.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/nextcloud-configmap.yaml → charts/nextcloud/1.6.47/templates/nextcloud-configmap.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/nginx-configmap.yaml → charts/nextcloud/1.6.47/templates/nginx-configmap.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/nginx-secret.yaml → charts/nextcloud/1.6.47/templates/nginx-secret.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/postgres-deployment.yaml → charts/nextcloud/1.6.47/templates/postgres-deployment.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/postgres-secret.yaml → charts/nextcloud/1.6.47/templates/postgres-secret.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/postgres-service.yaml → charts/nextcloud/1.6.47/templates/postgres-service.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/secrets.yaml → charts/nextcloud/1.6.47/templates/secrets.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/service.yaml → charts/nextcloud/1.6.47/templates/service.yaml


+ 0 - 0
charts/nextcloud/1.6.46/templates/serviceaccount.yaml → charts/nextcloud/1.6.47/templates/serviceaccount.yaml