I am new to gcp and kubernetes and while deploying a workload in a cluster I was stuck with this error "Error: horizontalpodautoscalers.autoscaling "nginx-1-hpa" already exists". Can any one help with this?
From the error message that you've shared, it seems that you are trying to create a Horizontal Pod Autoscaler that already exists.
To fix this, you will have to delete the Horizontal Pod Autoscaler named “nginx-1-hpa”.
The command to delete the HPA "nginx-1-hpa" is:
$ kubectl delete hpa nginx-1-hpa
After deleting the HPA, you will be able to deploy the workload.