Commit Graph

41 Commits

Author SHA1 Message Date
Ciprian Hacman 3597bddeaf Fix vet error 2023-11-04 05:57:08 +02:00
Ciprian Hacman 59ad9f5554 azure: Populate node labels from tags 2023-07-19 17:38:17 +03:00
Leïla MARABESE 9cdc30dfcb refactoring: utils functions to get info from tags 2023-07-12 16:23:25 +02:00
Leïla MARABESE 4a943d8235 refactoring client 2023-06-14 15:15:22 +02:00
Leïla MARABESE a6dd007479 get zone from uuid in identify 2023-05-11 17:01:42 +02:00
Jesse Haka 9df5534a13 add k8s node labels 2023-02-01 21:11:11 +02:00
Jesse Haka eaa1a6836e update OpenStack node identifier to use Identifier instead of LegacyIdentifier 2023-01-15 10:14:51 +02:00
Leïla MARABESE 2819855bec get default zone from client instead of environment 2022-12-12 14:46:35 +01:00
Leïla MARABESE 3b9a57efb7 scaleway nodeidentity 2022-12-07 11:49:53 +01:00
John Gardiner Myers d39ba74bd7 Change the control-plane IG role to "ControlPlane" in v1alpha3 API 2022-11-22 17:05:29 -08:00
Ciprian Hacman 35f12c12b1 azure: Update clients to latest (previous) versions 2022-11-08 19:47:17 +02:00
Ole Markus With 7ab7cfda69 Don't explicitly set karpenter provisioner label
It's past on as other labels through the CAS cloud labels
2022-08-24 12:39:52 +02:00
Ciprian Hacman b5f14b589b Add initial support for Hetzner Cloud 2022-05-09 06:12:15 +03:00
Ole Markus With ce2e877aeb Remove bazel files from vendor 2022-04-12 13:29:03 +02:00
Ole Markus With 70345699e7 Identify pending instances 2021-12-27 21:35:11 +01:00
Ole Markus With 75d2b97754 Set provider name on karpenter-managed node 2021-12-12 19:33:41 +01:00
Ciprian Hacman ea7df00719 Run hack/update-gofmt.sh 2021-12-01 22:39:50 +02:00
Eng Zer Jun 425173ae9f
refactor: move from io/ioutil to io and os packages
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil. This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2021-11-12 15:37:18 +08:00
justinsb a4621bc21d gce: don't over-warn on ManagedInstanceGroups filtering
It does seem that filtering is not yet implemented on this call.
Don't over-warn.

Also introduce pagination, because without a filter we might paginate.
2021-11-11 10:14:42 -05:00
burntcarrot 7a6e1c1e68 Fix new staticcheck errors
Signed-off-by: burntcarrot <aadhav.n1@gmail.com>
2021-08-28 19:48:17 +05:30
Kenji Kaneda a2bfbdd4cb Fix node label conversion in Azure
As Azure doesn't allow "/" in label keys, we used to convert "/" to
"_", but we didn't convert back "_" to "/" in kops-controller.

Change the code to store a label key in a tag value so that we don't
need to worry about escaping.
2021-02-28 22:35:12 -08:00
Kubernetes Prow Robot 2db0b18145
Merge pull request #10619 from NickSchleicher/azureNodeLabelTags
Use correct tag when creating node labels from azure cloud tags
2021-02-15 16:13:06 -08:00
Jesse Haka 034dad258c modify names 2021-02-05 09:57:54 +02:00
Jesse Haka 41d04d8d4b add user agent to openstack api requests 2021-02-04 23:04:06 +02:00
Nicholas Schleicher 617869e823 Use correct tag when creating node labels from azure cloud tags 2021-01-20 16:41:38 -05:00
Kenji Kaneda a61caea8d2 Add Azure support
This commit contains all changes required to support Azure
(https://github.com/kubernetes/kops/issues/3957).
2020-12-21 08:27:54 -08:00
John Gardiner Myers 7069aaabf6 Take node labels from cloud tags on AWS 2020-09-10 20:59:24 -07:00
John Gardiner Myers 24ff622d8e Rename NodeReconciler to LegacyNodeReconciler 2020-09-10 20:42:56 -07:00
Rodrigo Menezes 4c057f138a Allow caching of Nodeidentity Info in kops-controller for AWS to reduce the number of DescribeInstances API calls. 2020-09-09 22:11:29 +03:00
Peter Rifel 4d9f0128a3
Upgrade to klog2
This splits up the kubernetes 1.19 PR to make it easier to keep up to date until we get it sorted out.
2020-08-16 20:56:48 -05:00
Panagiotis Atmatzidis 31acabf8cd
Add EC2 instance lifecycle label to nodes
When using a "mixed instance policy"[1] instance group spot and onDemand nodes are part of the same
ASG. The ASG handles the percentage of spot vs onDemand instances. There are no annotations, EC2 tags or labels to identify which
instances are onDemand vs spot. There is a field called `InstanceLifecycle` accessible through `EC2.DescribeInstances`.

The field `InstanceLifecycle` is available only in `spot` and
`scheduled` AWS EC2 instance types.

This PR introduces a new label to be attached on AWS EC2 spot nodes.

The label is:

```
node-role.kubernetes.io/spot-worker: "true"
```

or

```
node-role.kubernetes.io/scheduled-worker: "true"
```

[^1]: https://github.com/kubernetes/kops/blob/master/docs/instance_groups.md#mixedinstancepolicy-aws-only
2020-05-15 09:33:37 +03:00
eric-hole f25b26ff07 Migrates GCE sdk from v0.beta to v1 2020-04-24 10:54:19 -07:00
Jesse Haka 8160889c9b fixes auth problem in case of openstack kops-controller 2020-04-07 08:11:45 +03:00
Justin Santa Barbara 5ebbfc96b9
Replace deprecated method calls to google cloud libraries
Required for static-check to pass.
2020-01-17 06:38:43 -05:00
tanjunchen 7e25f9831d nodeup/pkg/ pkg/ staticcheck 2019-12-31 15:03:39 +08:00
tanjunchen 977f987d65 fix-pkg-staticcheck and remove the repeat code 2019-12-03 10:32:37 +08:00
Srikanth 5ee945fc88 incorporate review comments 2019-11-24 12:56:46 +05:30
Srikanth 7b8eb2bfee Initial work for kops-controller to support digital ocean 2019-11-24 12:56:46 +05:30
Jesse Haka ed8dbc41d0 kops controller support for openstack 2019-09-28 10:06:39 +03:00
Justin SB cdaa7a3a48
Fix boilerplate: headers & packages 2019-09-25 12:48:14 -04:00
Justin SB 728e582360
Fill out kops controller functionality
k8s 1.16 requires that we move label setting away from the kubelet, to
a central controller.  kops-controller is that controller.
2019-09-25 12:04:34 -04:00