From a20fd9458924faaea0eb7783888a9087cd3e74ef Mon Sep 17 00:00:00 2001 From: elonzhou Date: Wed, 16 Sep 2020 00:06:06 +0800 Subject: [PATCH] fix/cronjob-request-host (#17) * fix #16 Signed-off-by: elonzh * bump version Signed-off-by: elonzh --- charts/nextcloud/Chart.yaml | 2 +- charts/nextcloud/README.md | 1 - charts/nextcloud/templates/cronjob.yaml | 9 +-------- charts/nextcloud/values.yaml | 2 -- 4 files changed, 2 insertions(+), 12 deletions(-) diff --git a/charts/nextcloud/Chart.yaml b/charts/nextcloud/Chart.yaml index 26bf12f3..6a7f2362 100644 --- a/charts/nextcloud/Chart.yaml +++ b/charts/nextcloud/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: nextcloud -version: 2.1.0 +version: 2.1.1 appVersion: 17.0.0 description: A file sharing server that puts the control and security of your own data back into your hands. keywords: diff --git a/charts/nextcloud/README.md b/charts/nextcloud/README.md index c4d186bc..613f3f34 100644 --- a/charts/nextcloud/README.md +++ b/charts/nextcloud/README.md @@ -117,7 +117,6 @@ The following table lists the configurable parameters of the nextcloud chart and | `cronjob.enabled` | Whether to enable/disable cronjob | `false` | | `cronjob.schedule` | Schedule for the CronJob | `*/15 * * * *` | | `cronjob.annotations` | Annotations to add to the cronjob | {} | -| `cronjob.curlInsecure` | Set insecure (-k) option to curl | false | | `cronjob.failedJobsHistoryLimit` | Specify the number of failed Jobs to keep | `5` | | `cronjob.successfulJobsHistoryLimit` | Specify the number of completed Jobs to keep | `2` | | `cronjob.resources` | Cronjob Resources | `nil` | diff --git a/charts/nextcloud/templates/cronjob.yaml b/charts/nextcloud/templates/cronjob.yaml index 25301d77..5de93d93 100644 --- a/charts/nextcloud/templates/cronjob.yaml +++ b/charts/nextcloud/templates/cronjob.yaml @@ -44,16 +44,9 @@ spec: imagePullPolicy: {{ default .Values.image.pullPolicy .Values.cronjob.image.pullPolicy }} command: [ "curl" ] args: - {{- if .Values.cronjob.curlInsecure }} - - "-k" - {{- end }} - "--fail" - "-L" - {{- if .Values.ingress.tls }} - - "https://{{ .Values.nextcloud.host }}/cron.php" - {{- else }} - - "http://{{ .Values.nextcloud.host }}/cron.php" - {{- end }} + - "http://{{ template "nextcloud.fullname" . }}:{{ .Values.service.port }}/cron.php" resources: {{ toYaml (default .Values.resources .Values.cronjob.resources) | indent 16 }} {{- with (default .Values.nodeSelector .Values.cronjob.nodeSelector) }} diff --git a/charts/nextcloud/values.yaml b/charts/nextcloud/values.yaml index 8e3cca06..3522c307 100644 --- a/charts/nextcloud/values.yaml +++ b/charts/nextcloud/values.yaml @@ -261,8 +261,6 @@ cronjob: # cause issues with how nextcloud background jobs are executed schedule: "*/15 * * * *" annotations: {} - # Set curl's insecure option if you use e.g. self-signed certificates - curlInsecure: false failedJobsHistoryLimit: 5 successfulJobsHistoryLimit: 2 # If not set, nextcloud deployment one will be set