fix: cronjob.batch/v1 is invalid in k8s v1.19 (#6178)

fix: auto update extension museum only when kubernetes version > =v1.20.0

Signed-off-by: joyceliu <joyceliu@yunify.com>
Co-authored-by: joyceliu <joyceliu@yunify.com>
This commit is contained in:
liujian
2024-09-18 16:35:08 +08:00
committed by GitHub
parent fc07b45607
commit 4afda8d02b
2 changed files with 2 additions and 2 deletions

View File

@@ -7,7 +7,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.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 1.1.1
version: 1.1.2
# 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

View File

@@ -51,7 +51,7 @@ spec:
url: http://extensions-museum.{{ .Release.Namespace }}.svc
---
apiVersion: batch/v1
apiVersion: {{ if semverCompare ">=1.20.0" .Capabilities.KubeVersion.Version }}batch/v1{{ else }}batch/v1beta1{{end}}
kind: CronJob
metadata:
name: restart-extensions-museum