livekit / livekit-helm

LiveKit Helm charts
https://docs.livekit.io
Apache License 2.0
50 stars 59 forks source link

Support Kubernetes 1.26 #74

Closed p4block closed 1 year ago

p4block commented 1 year ago

autoscaling/v2beta1 is deprecated and the helmchart tried to generate it. I've modified the output yaml for the new spec manually:


apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
(...)
  metrics:
    - type: Resource
      resource:
        name: cpu
        target:
          type: Utilization
          averageUtilization: 60
davidzhao commented 1 year ago

How did you generate the output YAML? It should already be generating autoscaling/v2 for Kube > 1.23:

{{- if semverCompare ">=1.23-0" .Capabilities.KubeVersion.GitVersion }}
apiVersion: autoscaling/v2
{{- else }}
apiVersion: autoscaling/v2beta1
{{- end }}
davidzhao commented 1 year ago

If you are using helm template, please ensure you are passing in --kube-version 1.26 to give it that context. I suspect that's what's happening here.

p4block commented 1 year ago

You're right, I was using helm template to avoid the TLS indentation problem in the other issue and I didn't know of the kube-version flag. I wrongly assumed it would query the current cluster for the version :/ Thanks a lot