Skip to content

[incubator/monochart]: CronJob is using deprecated batch/v1beta1 apiVersion  #277

@spiette

Description

@spiette

Describe the Bug

Current Job is fine, but CronJob still uses batch/v1beta1 which is not available since Kubernetes v1.25

Applying a cronJob on Kubernetes >= 1.25 get rejected by Kubernetes API server

Expected Behavior

Generated cronJob resources should be accepted.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Deploy Kubernetes >=1.25 (minikube, kind)
  2. Edit values.yaml to have cronJobs.default.enabled to true
  3. helm template monochart . | kubectl apply --dry-run=server -f -
  4. See error
error: resource mapping not found for name: "monochart-monochart-default" namespace: "" from "STDIN": no matches for kind "CronJob" in version "batch/v1beta1"
ensure CRDs are installed first

Environment:

  • kubectl 1.28.2
  • kind 0.17.0
  • helm version 3.11
  • incubator/monochart 0.28.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions