From f87005bb3aeb84786aae46d3a91357a28c9e5f90 Mon Sep 17 00:00:00 2001 From: Michael Haehnel Date: Fri, 20 Jan 2023 18:07:40 +0100 Subject: [PATCH] Adding WP Cronjob here --- Chart.yaml | 6 +++--- templates/cronjob_wordpress.yaml | 21 +++++++++++++++++++++ values_nsodev.yaml | 1 - 3 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 templates/cronjob_wordpress.yaml diff --git a/Chart.yaml b/Chart.yaml index 9cb8a1c..433e972 100644 --- a/Chart.yaml +++ b/Chart.yaml @@ -15,13 +15,13 @@ 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. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.1.12 +version: 0.1.13 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "0.1.11" +appVersion: "0.1.12" dependencies: - name: tenant @@ -34,5 +34,5 @@ dependencies: version: 0.1.5 repository: oci://prodnso-harbor-01.smardigo.digital/smardigo - name: smardigo-wordpress - version: 0.1.13 + version: 0.1.14 repository: oci://prodnso-harbor-01.smardigo.digital/smardigo diff --git a/templates/cronjob_wordpress.yaml b/templates/cronjob_wordpress.yaml new file mode 100644 index 0000000..462a590 --- /dev/null +++ b/templates/cronjob_wordpress.yaml @@ -0,0 +1,21 @@ +apiVersion: batch/v1 +kind: CronJob +metadata: + name: wp-cron +spec: + schedule: "30 * * * *" + concurrencyPolicy: Forbid + jobTemplate: + spec: + template: + spec: + containers: + - name: wp-cron + image: busybox:1.28 + imagePullPolicy: IfNotPresent + command: + - /bin/wget + - --no-check-certificate + - -q + - "https://{{ .Values.smardigo-wordpress.wordpress.ingress.hostname }}/wp-admin.php" + restartPolicy: OnFailure \ No newline at end of file diff --git a/values_nsodev.yaml b/values_nsodev.yaml index 8edd775..c4ec681 100644 --- a/values_nsodev.yaml +++ b/values_nsodev.yaml @@ -108,4 +108,3 @@ smardigo-wordpress: wp plugin install https://updraftplus.com/wp-content/uploads/updraftplus.zip --activate-network ingress: hostname: connect-wordpress-nsodev-prodwork01.smardigo.digital - \ No newline at end of file