Commit Graph

1872 Commits

Author SHA1 Message Date
John Gardiner Myers 2420991954 Determine default API access method by IG subnet type 2023-07-18 22:21:05 -07:00
John Gardiner Myers f1f8b0637b Enable NTH by default on AWS 2023-07-18 16:13:22 -07:00
John Gardiner Myers 850abfbc68 Get VFSContext from caller in misc. places 2023-07-18 09:22:29 -07:00
John Gardiner Myers 5c343b0f80 Get VFSContext from caller in CopyFile 2023-07-18 09:22:24 -07:00
John Gardiner Myers 1358851c7d Get VFSContext from caller in NewAssetBuilder() 2023-07-18 08:49:06 -07:00
John Gardiner Myers 76ed6b9e27 Get VFSContext from caller in ValidateCluster() 2023-07-17 22:20:57 -07:00
John Gardiner Myers 7489469414 Get VFSContext from caller in ConfigBase() 2023-07-17 21:56:01 -07:00
John Gardiner Myers 245cd64a3a Get VFSContext from caller in LoadChannel() 2023-07-17 21:45:43 -07:00
Kubernetes Prow Robot 5d08bc3b0a
Merge pull request #15640 from johngmyers/vfscontext
Refactor out references to global vfs.Context
2023-07-17 09:15:19 -07:00
Kubernetes Prow Robot 76eda9b9f4
Merge pull request #15650 from justinsb/prune_node_labels
Support removal of managed node labels
2023-07-16 21:49:07 -07:00
justinsb 7a5c43ef8d Fix comment on patchNodePodCIDRs
Cleanup; no change in behavior.
2023-07-16 22:59:06 -04:00
justinsb 5fd533c96a Support removal of managed node labels
kops-controller manages a few node-role node-labels.  We
now remove any extra managed labels that land on the node.

This means we will now actively remove the extra node label if we
previously erroneously applied to a control-plane node; previous code
changes stopped applying it.
2023-07-16 22:41:22 -04:00
John Gardiner Myers 977aacc356 Remove dead code for non-kops-controller bootstrap 2023-07-16 07:40:25 -07:00
Kubernetes Prow Robot 2a0cc8a7dc
Merge pull request #15627 from hakman/azure_dns_none
azure: Add support for dns=none
2023-07-16 04:27:05 -07:00
Kubernetes Prow Robot a669604f55
Merge pull request #15608 from justinsb/load_versioned_api
kops-controller: load objects with version conversion
2023-07-15 17:31:05 -07:00
John Gardiner Myers e04fc1314f Use NewVFSContext in kops-controller 2023-07-15 15:48:56 -07:00
Kubernetes Prow Robot ef284b11e5
Merge pull request #14960 from johngmyers/vfscontext
Add VFSContext to various clientsets
2023-07-15 14:55:05 -07:00
justinsb edeb4d4869 kops-controller: load objects with version conversion
If we deserialize the yaml, we don't go through the version-conversion
logic.  That logic maps from Master -> ControlPlane, so without that
logic we see unexpected values in the "string enums".
2023-07-15 17:34:50 -04:00
Kubernetes Prow Robot 141a040aec
Merge pull request #15607 from hakman/gce_cloud-init
gce: Use `user-data` instead of `startup-script` metadata key
2023-07-15 11:47:05 -07:00
Ciprian Hacman 83d14d4343 azure: Add support for dns=none 2023-07-13 09:04:06 +03:00
John Gardiner Myers aef6fbdd29 Refactor UseKopsControllerForNodeBootstrap() 2023-07-11 09:45:45 -07:00
justinsb d6350a5a6e etcd-manager: support symlinking versions
This is an easy way for us to signal that certain versions are
compatible with each to etcd-manager, which is otherwise
overly-cautious when it comes to unknown versions.

We extend kops-utils to support the `-t` flag (like cp) to write to a
directory; and the `-s` flag (like cp) to use symlinks.  The syntax
isn't identical to cp, but should be semi-familiar and allows us to
minimize the number of initContainers we use.
2023-07-10 11:11:59 -04:00
John Gardiner Myers d926989600 v1alpha3: Rename GCE networking to GCP 2023-07-09 16:48:26 -07:00
Ciprian Hacman fb66f1770f gce: Use `user-data` instead of `startup-script` metadata key 2023-07-09 13:50:00 +03:00
John Gardiner Myers 11304807f2 Hold reference to VFSContext from simple.Clientset 2023-07-06 19:41:45 -07:00
John Gardiner Myers 64903eb166 Hold reference to VFSContext from Factory 2023-07-06 19:41:45 -07:00
Kubernetes Prow Robot e0543b89b2
Merge pull request #15593 from hakman/increase_client-side_throttlling_limits
Increase client-side throttling limits
2023-07-05 20:13:03 -07:00
Justin SB cf9134489c kops-controller: create IPAM controller for GCE
We observe the IPv6 CIDRs assigned to nodes, and reflect them into the node.

Co-authored-by: John Gardiner Myers <jgmyers@proofpoint.com>
2023-07-05 12:34:55 -04:00
Ciprian Hacman ba442011d7 Increase client-side throttling limits 2023-07-05 13:22:53 +03:00
Tone c2ed4b6f64
Upgrade Karpenter to v0.27.5 (#15144)
* feat(karpenter): Upgrade to version 0.27.0

Upgrade Karpenter to current last stable version `0.27.0`.
Template have been updated to use the same templates than the Helm chart.

* feat(karpenter): Use AWSNodeTemplate for launchTemplate

To set Launch Templates is deprecated into the provisioner, it is recommends using the `AWSNodeTemplate` to set it.
Ref:
 - https://karpenter.sh/v0.27.0/concepts/node-templates/

* feat(karpenter): Enable pruning addon

* Use extra flags in upgrade-ab scenario test

* feat(karpenter): Drop `karpenter` feature flag

* feat(karpenter): Add release note for `1.27`

* feat(karpenter): Upgrade to version 0.27.3

* feat(karpenter):  fix template

* feat(karpenter): Upgrade to version 0.27.5

* Update Karpenter documentation with depending kops version

* Delete KOPS_FEATURE_FLAGS from e2e test `run-test`

* Run hack/update-expected.sh
2023-06-29 22:57:45 -07:00
Ciprian Hacman 246da5a548 Add create cluster flag for specifying the list of etcd clusters 2023-06-27 17:14:09 +03:00
John Gardiner Myers 37f67231b6 Remove 1.22 create cluster integration test 2023-06-22 23:03:24 -07:00
John Gardiner Myers 0dfac69d83 Remove support for Weave networking 2023-06-22 23:03:24 -07:00
Kubernetes Prow Robot 9cbb48c4a2
Merge pull request #15458 from peaaceChoi/master
Support intstr.IntOrString type  in cmd
2023-06-22 07:13:40 -07:00
Ciprian Hacman 26198a22b2 Update tests for kOps v1.28 2023-06-20 08:11:21 +03:00
justinsb 36a763c88f node labeling: don't ignore unknown roles
We were silently ignoring unknown roles, which makes it hard to know
when our expectations aren't met.  It looks like the rename of the
role from "Master" to "ControlPlane" may have caused some drift
against our expectations also.
2023-06-18 19:40:56 -04:00
Ciprian Hacman bec7226ad1 Rename `kops-copy` to `kops-utils-cp` 2023-06-16 22:24:51 +03:00
Leïla MARABESE b9807d49e8 update expected + headers 2023-06-14 15:47:30 +02:00
Leïla MARABESE dab001c3e9 scaleway authenticator and verifier 2023-06-14 15:15:17 +02:00
Ciprian Hacman 53a9be0bba Add integration tests for K8s 1.27 2023-06-07 14:52:25 +03:00
Kubernetes Prow Robot fe3e5cd6e1
Merge pull request #15436 from hakman/etcd-3.5.9
Update etcd to v3.5.9
2023-05-31 10:25:48 -07:00
Pyeongkang Choi 0a862fdb70
Support intstr.IntOrString type 2023-05-31 16:38:04 +09:00
Ciprian Hacman f246cbe4f9 Use `filepath` instead of `path` 2023-05-31 07:44:13 +03:00
Ciprian Hacman 505c0c87de kops-controller: Return `http.StatusConflict` only when node is ready 2023-05-27 12:58:50 +03:00
Ciprian Hacman 7b545dde4b kops-controller: Return `http.StatusConflict` when node already exists 2023-05-27 09:47:40 +03:00
Ciprian Hacman f51e347f99 Build and use cp replacement 2023-05-27 05:18:53 +03:00
Kubernetes Prow Robot e3a639cd73
Merge pull request #15373 from hakman/depup
Update dependencies to K8s v1.27
2023-05-08 02:27:17 -07:00
Ciprian Hacman 43dc946522 Hide s2a flags from --help output 2023-05-08 07:35:36 +03:00
justinsb 1faee9dd8c digitalocean: bootstrap nodes through kops-controller.
We start with a simple node verifier.
2023-05-07 13:17:56 -04:00
justinsb c89f434f1b Only use node challenge on hetzner
DigitalOcean (and others) will follow shortly.

Also create a method for CloudProvider, so that we are more ambivalent
towards bootstrapping methods.
2023-05-06 08:57:21 -04:00
Justin SB c67f895226 Perform challenge callbacks into a node
In order to verify that the caller is running on the specified node,
we source the expected IP address from the cloud, and require that the
node set up a simple challenge/response server to answer requests.

Because the challenge server runs on a port outside of the nodePort
range, this also makes it harder for pods to impersonate their host
nodes - though we do combine this with TPM and similar functionality
where it is available.
2023-05-06 08:03:21 -04:00
justinsb 868823bbcf Block bootstrap when the node already exists
We now do this across all clouds, as it has been demonstrated on
OpenStack.
2023-04-27 11:47:42 -04:00
Leïla MARABESE 1e20a4c629 unique instance names to comply with CCM 2023-04-25 16:01:42 +02:00
Leïla MARABESE b4d230f8c2 scaleway integration test 2023-03-28 16:58:54 +02:00
Ciprian Hacman dc92df3643 gcp: Add placeholder integration test for public load balancer 2023-03-16 07:49:47 +02:00
Jesse Haka a765191898 use http.StatusConflict 2023-02-20 13:01:43 +02:00
Jesse Haka 8e6199fa39 exit gracefully if server already exists in k8s 2023-02-12 16:52:13 +02:00
Justin SB 9b02017059 openstack verifier: support IPv6
Add IPv6 support to the openstack verifier and polish up a few error messages.
2023-01-28 10:54:48 -05:00
Jesse Haka b3c134be06 make openstack kops-controller boostrap auth better 2023-01-19 10:07:11 +02:00
Kubernetes Prow Robot 08f308232f
Merge pull request #15006 from zetaab/osnodeidentifier
update OpenStack node identifier to use Identifier
2023-01-15 23:20:51 -08:00
Jesse Haka eaa1a6836e update OpenStack node identifier to use Identifier instead of LegacyIdentifier 2023-01-15 10:14:51 +02:00
John Gardiner Myers 775ed65820 Run kops-controller server on non-leaders as well 2023-01-14 10:20:04 -08:00
Jesse Haka 3dab0eb807 Use kops-controller to boostrap nodes in OpenStack 2023-01-14 13:54:14 +02:00
Ciprian Hacman d884e5f4d9 Remove the SpecOverrideFlag feature flag 2023-01-13 20:40:17 +02:00
Kubernetes Prow Robot a1a0ce3f33
Merge pull request #14930 from zetaab/feature/openstacknodns
OpenStack: Add support for clusters without DNS
2023-01-12 07:52:54 -08:00
Kubernetes Prow Robot a7a77026e1
Merge pull request #14920 from dimamo5/replace-using-defaults
Populate cluster with default values in `kops replace`
2023-01-12 03:08:54 -08:00
Diogo Moura 05a0a96d8b
Wrap error using '%w'
Co-authored-by: Ole Markus With <olemarkus@gmail.com>
2023-01-12 10:22:23 +00:00
Jesse Haka cc8871eede no dns for OpenStack 2023-01-11 20:02:02 +02:00
Grégory SANCHEZ 1b35c353d3 test(cas): add integration tests for cluster autoscaler priority expander config 2023-01-11 08:26:33 +01:00
Kubernetes Prow Robot 7b4430ff61
Merge pull request #14885 from johngmyers/root-volume
v1alpha3: Move IG root volume settings to sub-struct
2023-01-04 18:11:58 -08:00
John Gardiner Myers c68be498c6 Refactor NewAssetBuilder to not take a Cluster 2023-01-01 13:37:52 -08:00
justinsb 6c2edaee7e Add Context arg to vfs ReadFile
This is an "action" method, so should take a context.
2023-01-01 09:51:44 -05:00
Diogo Moura 4ead1abd87
Populate cluster with default values in `kops replace` 2022-12-31 00:31:12 +00:00
John Gardiner Myers 309c893ca1 Include SSHCredentials in create cluster dryrun output 2022-12-27 22:49:15 -08:00
John Gardiner Myers 92958f9966 v1alpha3: Move IG root volume settings to sub-struct 2022-12-26 20:35:26 -08:00
Ciprian Hacman b3a07ee83e Use short service name with discovery labels 2022-12-26 13:21:43 +02:00
John Gardiner Myers 005ec38972 Remove code for no-longer-supported k8s 1.21 2022-12-24 21:44:50 -08:00
John Gardiner Myers c0dff11230 Update min versions for 1.27 2022-12-24 21:44:49 -08:00
justinsb 817c1e63b3 FindKeyset can return nil
We had missed a case in nodeup; add a Context argument to force us to
revisit the codepaths.
2022-12-24 16:12:21 -05:00
Kubernetes Prow Robot 69c59af0f4
Merge pull request #14862 from justinsb/vfs_context_to_create_and_write
VFS: Add context to CreateFile & WriteFile
2022-12-23 10:25:26 -08:00
justinsb a69dc902c4 Add context to GetOrCreateSecret
Continuing the wiring as needed.
2022-12-23 10:48:50 -05:00
justinsb ae074bbc6b VFS: Add context to CreateFile & WriteFile
As "request" methods, these should have context parameters.
2022-12-23 10:39:52 -05:00
justinsb ba59d65bc9 Wire up context from cobra in cmd/kops
Removes a lot of context.TODO() calls.
2022-12-22 17:52:27 -05:00
justinsb 90cbf75584 Context threading: more wiring
We're aiming to use this for testing immediately and better
logging/tracing in future, but to make the changes manageable breaking
them into a smaller series that don't directly achieve much.
2022-12-22 17:52:22 -05:00
Ole Markus With d9e2490439 Add node local dns to many-addons irsa test 2022-12-20 22:11:44 +01:00
John Gardiner Myers 76fc186060 Remove nodeup's unused cloudinit target 2022-12-20 07:14:15 -08:00
John Gardiner Myers 7c3e32369a Refactor Context into separate cloudup and nodeup types 2022-12-17 17:42:46 -08:00
Kubernetes Prow Robot 0f5fc06cec
Merge pull request #14771 from johngmyers/sqs-rebalance
Don't drain on rebalance recommendations in SQS mode unless configured
2022-12-17 07:15:42 -08:00
Kubernetes Prow Robot 0896ea246d
Merge pull request #14769 from hakman/gce_none_dns
gce: Add support for clusters without DNS
2022-12-15 19:29:36 -08:00
Ciprian Hacman cfa5a670d4 Add integration tests 2022-12-14 11:54:06 +02:00
Ciprian Hacman 0ff7c6f432 Update GCE integration tests 2022-12-14 11:48:51 +02:00
John Gardiner Myers 20b5241b84 Get AWS zones list from AWS SDK 2022-12-13 22:50:11 -08:00
Kubernetes Prow Robot 41fa042b89
Merge pull request #14768 from hakman/guess_cloud
Guess cloud provider from state store path
2022-12-13 22:29:40 -08:00
Kubernetes Prow Robot c9e6a915cc
Merge pull request #14736 from Mia-Cross/scaleway_nodeidentity
scaleway : nodeidentity
2022-12-13 22:29:34 -08:00
John Gardiner Myers 55b46073b7 Don't drain on rebalance recommendations in SQS mode unless configured 2022-12-11 18:21:43 -08:00
Ciprian Hacman bc2aa3072d Guess cloud provider from state store path 2022-12-11 12:30:10 +02:00
Ole Markus With 7375bbb487 kops-controller: increase verbosity level on logs in gossip controller 2022-12-08 20:18:31 +01:00
Ole Markus With 160941e1b5 Add openstack octavia integration test 2022-12-07 21:47:42 +01:00
Leïla MARABESE 3b9a57efb7 scaleway nodeidentity 2022-12-07 11:49:53 +01:00
Kubernetes Prow Robot f827ec7f54
Merge pull request #14721 from johngmyers/nth-default-queue
Change default for NTH Queue Processor mode to enabled
2022-12-06 03:18:36 -08:00