[release-4.1] config/ks-core: fix the CronJob API version determination issue (#6229)

config/ks-core: fix the CronJob API version determination issue

Co-authored-by: Xinzhao Xu <z2d@jifangcheng.com>
This commit is contained in:
KubeSphere CI Bot
2024-10-18 14:23:42 +08:00
committed by GitHub
parent 4efc7c9fbe
commit 3798bcd452

View File

@@ -86,7 +86,7 @@ spec:
caBundle: {{ b64enc $ca.Cert }}
---
apiVersion: {{ if semverCompare ">=1.20.0" .Capabilities.KubeVersion.Version }}batch/v1{{ else }}batch/v1beta1{{end}}
apiVersion: {{ if semverCompare ">=1.21.0-0" .Capabilities.KubeVersion.Version }}batch/v1{{ else }}batch/v1beta1{{end}}
kind: CronJob
metadata:
name: restart-extensions-museum