helm3 upgrade error unknown field "metrics" in io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerSpec
Summary
Testing a helm3 v3.4.2
upgrade gitlab-com/gl-infra/delivery#1399 (closed) for the GitLab Chart we are running into the following error:
Error: unable to build kubernetes objects from release manifest: error validating "": error validating data: ValidationError(HorizontalPodAutoscaler.spec): unknown field "metrics" in io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerSpec
I assume the error is coming from https://gitlab.com/gitlab-org/charts/gitlab/-/blob/efc0b6bf4fb30e744e255a9a98e1c64b3f08704f/charts/nginx/templates/controller-hpa.yaml#L4 where we use apiVersion: autoscaling/v1
. Though it's not clear to me why it's only happening to us.
(Summarize the bug encountered, concisely as possible)
Steps to reproduce
(Please provide the steps to reproduce the issue)
Configuration used
(Please provide a sanitized version of the configuration used wrapped in a code block (```yaml))
(Paste sanitized configuration here)
Current behavior
(What you're experiencing happening)
Expected behavior
(What you're expecting to happen)
Versions
- Chart: (tagged version | branch | hash
git rev-parse HEAD
) - Platform:
- Cloud: (GKE | AKS | EKS | ?)
- Self-hosted: (OpenShift | Minikube | Rancher RKE | ?)
- Kubernetes: (
kubectl version
)- Client:
- Server:
- Helm: (
helm version
)- Client:
- Server:
Relevant logs
(Please provide any relevate log snippets you have collected, using code blocks (```) to format)