kubernetes / autoscaler

Autoscaling components for Kubernetes
Apache License 2.0
7.93k stars 3.93k forks source link

Helm functionnal for Rancher with cloudconfig in a secret #6785

Open etchevef opened 4 months ago

etchevef commented 4 months ago

Which component are you using?:

cluster-autoscaler, its Helm charts and the Rancher Cloud Provider.

Is your feature request designed to solve a problem? If so describe the problem this feature should solve.:

The cluster-autoscaler binary is functionnal with rancher, the Helm charts should permit to deploy a similarly functionnal cluster-autoscaler deployment using the Rancher cloud provider, even if not officially supported.

Describe the solution you'd like.:

I want helm parameters corresponding to the values from the rancher cloudconfig, so that I can have a functionnal deployment when chosing the rancher cloud provider. The corresponding cloudconfig file should be added as a kubernetes secret to be mounted as a volume in the cluster-autoscaler pod.

Describe any alternative solutions you've considered.:

There is a cloudConfigPath parameter already there to mount the cloudConfig from a file on the nodes, but that doesn't feel right and more importantly I don't see how that would work in rancher without also meddling with rancher's node drivers.

Additional context.:

I have implemented this feature for me, hopefuly I'll be linking a pull request to this issue shortly.

I've added a parameter "cloudConfigMethod" that defaults to working with the path as it currently does, but can be switched to "Secret" to use my new parameters and generate the cloudconfig in a secret. My secret will only be populated if cloud provider is rancher though.

etchevef commented 4 months ago

My corresponding PR, not sure how to correctly link issue and PR (If I should do that at all ?)

6786

adrianmoisey commented 1 month ago

/area cluster-autoscaler