autoscaler
autoscaler copied to clipboard
cluster autoscaler provider build tags broken for several providers
Which component are you using?:
cluster-autoscaler
What version of the component are you using?:
Component version: master
What k8s version are you using (kubectl version)?:
n/a
What environment is this in?:
n/a, build environment
What did you expect to happen?:
expect target binary to be built
What happened instead?:
$ go build --tags aws -o ./cluster-autoscaler-amd64
# k8s.io/autoscaler/cluster-autoscaler/cloudprovider/builder
cloudprovider/builder/cloud_provider_builder.go:46:47: too many arguments in call to buildCloudProvider
have ("k8s.io/autoscaler/cluster-autoscaler/config".AutoscalingOptions, "k8s.io/autoscaler/cluster-autoscaler/cloudprovider".NodeGroupDiscoveryOptions, *"k8s.io/autoscaler/cluster-autoscaler/cloudprovider".ResourceLimiter, informers.SharedInformerFactory)
want ("k8s.io/autoscaler/cluster-autoscaler/config".AutoscalingOptions, "k8s.io/autoscaler/cluster-autoscaler/cloudprovider".NodeGroupDiscoveryOptions, *"k8s.io/autoscaler/cluster-autoscaler/cloudprovider".ResourceLimiter)
How to reproduce it (as minimally and precisely as possible):
run the following
go build --tags aws -o ./cluster-autoscaler-amd64
Anything else we need to know?:
pr #5820 added an argument to the buildCloudProvider function, when building for all tags or kwok the build works fine, but when specifying a provider which has not implemented the builder change then the error listed above happens on build.
this is fairly easy to fix, but requires updating many of the builder files. an example fix can be seen in #6491
providers that need fixing:
- alicloud
- aws
- azure
- baiducloud
- bizflycloud
- brightbox
- cherry
- civo
- cloudstack
- digitalocean
- exoscale
- externalgrpc
- gce
- hetzner
- huaweicloud
- ionoscloud
- kamatera
- kubemark
- linode
- magnum
- oci
- ovhcloud
- equinixmetal
- rancher
- scaleway
- tencentcloud
- volcengine
- vultr
/good-first-issue /help-wanted
@elmiko: This request has been marked as suitable for new contributors.
Guidelines
Please ensure that the issue body includes answers to the following questions:
- Why are we solving this issue?
- To address this issue, are there any code changes? If there are code changes, what needs to be done in the code and what places can the assignee treat as reference points?
- Does this issue have zero to low barrier of entry?
- How can the assignee reach out to you for help?
For more details on the requirements of such an issue, please see here and ensure that they are met.
If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-good-first-issue command.
In response to this:
/good-first-issue /help-wanted
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
Thanks, @elmiko for highlighting this issue. /triage accepted
I would like to work on it. /assign
Fixed it here: #6494
Fixed it here: #6494
Hi @elmiko, It will be good if we cherry-pick this fix to the previous release(releases after this PR #5820). what do you think about this?
@Shubham82 probably a good idea, although the breaking change only came in recently so i would double check to see how far we need to backport.
I checked these changes were merged in CA 1.29, before CA 1.29 go build command --tag is working fine. We have to backport these changes to the cluster-autoscaler-release-1.29 branch.
I will raise a PR for it once PR #6494 is merged.
thanks @Shubham82 !
I checked these changes were merged in CA 1.29, before CA 1.29
go build command --tagis working fine. We have to backport these changes to the cluster-autoscaler-release-1.29 branch.I will raise a PR for it once PR #6494 is merged.
I have opened PR #6590 to backport the changes to the cluster-autoscaler-release-1.29 branch.
closing this issue, as corresponding PRs are merged.
/close
@Shubham82: Closing this issue.
In response to this:
/close
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.