diff --git a/src/utils/constants.js b/src/utils/constants.js index 1235e019b47..2d6c2ef66ef 100644 --- a/src/utils/constants.js +++ b/src/utils/constants.js @@ -961,7 +961,7 @@ export const API_VERSIONS = { statefulsets: 'apis/apps/v1', daemonsets: 'apis/apps/v1', jobs: 'apis/batch/v1', - cronjobs: 'apis/batch/v1beta1', + cronjobs: 'apis/batch/v1', pods: 'api/v1', namespaces: 'api/v1', services: 'api/v1', @@ -984,7 +984,7 @@ export const API_VERSIONS = { applications: 'apis/app.k8s.io/v1beta1', strategies: 'apis/servicemesh.kubesphere.io/v1alpha2', servicepolicies: 'apis/servicemesh.kubesphere.io/v1alpha2', - horizontalpodautoscalers: 'apis/autoscaling/v2beta2', + horizontalpodautoscalers: 'apis/autoscaling/v2', customresourcedefinitions: 'apis/apiextensions.k8s.io/v1', clusters: 'apis/cluster.kubesphere.io/v1alpha1', workspaces: 'apis/tenant.kubesphere.io/v1alpha2', diff --git a/src/utils/form.templates.js b/src/utils/form.templates.js index 745f99c96af..21600132982 100644 --- a/src/utils/form.templates.js +++ b/src/utils/form.templates.js @@ -184,7 +184,7 @@ const getJobTemplate = ({ namespace }) => ({ }) const getCronJobTemplate = ({ namespace }) => ({ - apiVersion: 'batch/v1beta1', + apiVersion: 'batch/v1', kind: 'CronJob', metadata: { namespace, @@ -287,7 +287,7 @@ const getSecretTemplate = ({ namespace }) => ({ }) const getHorizontalPodAutoscalerTemplate = ({ name, namespace, target }) => ({ - apiVersion: 'autoscaling/v2beta2', + apiVersion: 'autoscaling/v2', kind: 'HorizontalPodAutoscaler', metadata: { name, diff --git a/src/utils/workload.js b/src/utils/workload.js index 6d65f5fec45..cd6b2c00b98 100644 --- a/src/utils/workload.js +++ b/src/utils/workload.js @@ -73,7 +73,7 @@ export const getHpaFormattedData = (formData = {}) => { : [] const data = merge(formData, { - apiVersion: 'autoscaling/v2beta2', + apiVersion: 'autoscaling/v2', kind: 'HorizontalPodAutoscaler', metadata: { annotations: {