Commit Graph

12860 Commits

Author SHA1 Message Date
Lubomir I. Ivanov
b872b55ff7 kubeadm: always retry Patch() Node API calls
The PatchNodeOnce function has historically exited early
in scanarious when we Get a Node object, but the next Patch
API call on the same Node object fails. This can happen
in setups that are under a lot of resource pressure
or different network timeout scenarious.

Instead of exiting early and allow listing certain errors,
always retry on any Patch error. This aligns with the
general idea that kubeadm retries *all* API calls.
2026-01-07 14:27:46 +01:00
Lubomir I. Ivanov
ed5a8b6b66 kubeadm: do not sort extraArgs alpha-numerically
If the user has provided extraArgs with an order that has
significance (e.g. --service-account-issuer for kube-apiserver),
kubeadm will correctly override any base args, but will end up
sorting the entire resulting list, which is not desired.

Instead, only sort the base arguments and preserve the order
of overrides provided by the user.
2025-12-19 17:43:40 +01:00
Andrey Borovets
b00d0b5e7c [Manual bugfix]: unhide the etcd-join phase for v1.34
Signed-off-by: Andrey Borovets <andrey.borovets@flant.com>

add import

Signed-off-by: Andrey Borovets <andrey.borovets@flant.com>

delete import
2025-11-27 14:18:12 +03:00
Kubernetes Prow Robot
732ead8c40 Merge pull request #134723 from neolit123/automated-cherry-pick-of-#134715-origin-release-1.34
Automated cherry pick of #134715: kubeadm: add missing cluster-info context validation
2025-11-07 18:12:59 -08:00
joshjms
e1e4e2eb44 etcd: bump etcd to v3.5.24 for k8s v1.31, v1.32, v1.33
Signed-off-by: joshjms <joshjms1607@gmail.com>
2025-10-25 01:20:04 +08:00
Lubomir I. Ivanov
60e3b5762c kubeadm: add missing cluster-info context validation
When retrieving the cluster-info CM, ensure the cluster pointed
out by the current context in the kubeconfig is validated.

Add unit test for the above.

Make the function GetClusterFromKubeConfig() to return various
errors. Handle the errors on call sites. Add unit tests
for the update.

The above changes prevent panics when the users has manually
edited and malformed the kubeconfig in the cluster-info CM.
2025-10-20 13:34:04 +02:00
Benjamin Wang
f3b637f6c3 Bump etcd to v3.6.5
Signed-off-by: Benjamin Wang <benjamin.ahrtr@gmail.com>
2025-10-16 21:18:37 +01:00
Jordan Liggitt
f40e4ce552 Remove invalid SAN certificate construction 2025-10-14 09:35:42 -04:00
Benjamin Elder
ed6bf3e5db kubeadm preflight checks: fix host URL construction 2025-10-14 09:35:42 -04:00
Lubomir I. Ivanov
3ffc54a9e9 kubeadm: rework the FetchInitConfigurationFromCluster node flags
The newControlPlane flag has been historically problematic, since
it implies that the function FetchInitConfigurationFromCluster
cannot handle the cases where a node is worker node but
we still want to fetch its NodeRegistrationOptions conditionally,
in cases such as "upgrade node" for workers.

To fix this issue, replace the flag newControlPlaneNode with
two new flags getNodeRegistration and getAPIEndpoint.

If getNodeRegistration is true, we fetch the NRO, and if
getAPIEndpoint is true, we fetch the API endpoint for
that node.

Additionally, rename skipComponentConfigs to getComponentConfigs
for consistency and flip its value accordingly everywhere.
2025-10-01 22:07:30 +02:00
Lubomir I. Ivanov
e9f5e892f7 kubeadm: use JoinHostPort in WaitControlPlaneClient
Using naive string concat with ":" does not work for IPv6.
Apply the fix to WaitForKubelet as well.
2025-09-25 21:26:38 +02:00
Lubomir I. Ivanov
663664c617 kubeadm: ensure waiting for apiserver uses a local client
When waiting for the kube-apiserver to report 'ok'
in the 'init' and 'join' phase 'wait-control-plane', a client
constructed from the 'admin.conf' is used. In the case of the
kube-apiserver, the discovery client is used so that
anonymous-auth works. But if 'admin.conf' is used as is,
it would point to the CPE and not the LAE.

Implement a new method WaitControlPlaneClient() for both
init.go and join.go that patches the 'Server' field in the
loaded v1.Config to point to the LAE, before constructing
a client set and using it in the kube-apiserver waiter.
2025-09-25 15:57:55 +02:00
tom1299
08515c751b Fix missing control plane health check timeout 2025-08-28 22:56:12 +08:00
Predrag Rogic
f2170bc6c3 kube-proxy: log but don't exit if ipv4 or ipv6 is not available 2025-08-26 16:11:12 +01:00
Ivan Valdes
e8dc272c53 Update etcd to 3.6.4 2025-07-27 21:45:02 -07:00
Kubernetes Prow Robot
802198e2da Merge pull request #133113 from alaypatel07/resource-claim-concurrent-syncs
bump resource claim controller concurrent syncs to 50
2025-07-24 17:59:20 -07:00
Kubernetes Prow Robot
1451dd1b08 Merge pull request #132942 from thockin/kyaml
Add KYAML support to kubectl
2025-07-24 17:59:06 -07:00
Kubernetes Prow Robot
7912e5fd67 Merge pull request #131549 from carlory/KEP-3751-GA
[Kep-3751] Promote VolumeAttributesClass to GA
2025-07-24 16:44:27 -07:00
Kubernetes Prow Robot
ebbebe8be6 Merge pull request #133157 from haircommander/cgroup-driver-cri-ga
KEP 4033: Add metric for out of support CRI and bump feature to GA
2025-07-24 13:05:04 -07:00
Tim Hockin
7adcd21148 Replace cmd/yamlfmt with k-sigs/yaml/yamlfmt
And run it.
2025-07-24 12:11:04 -07:00
carlory
94bf8fc8a9 Promoted API VolumeAttributesClass and VolumeAttributesClassList to storage.k8s.io/v1.
Promoted feature-gate `VolumeAttributesClass` to GA (on by default)

Signed-off-by: carlory <baofa.fan@daocloud.io>
2025-07-25 01:53:59 +08:00
Kubernetes Prow Robot
a11bc701e8 Merge pull request #132457 from ania-borowiec/depends_on_cluster_move_podinfo
Moving Scheduler interfaces to staging: Move PodInfo and NodeInfo interfaces (together with related types) to staging repo, leaving internal implementation in kubernetes/kubernetes/pkg/scheduler
2025-07-24 09:38:27 -07:00
Peter Hunt
5dc2030c02 4033: GA KubeletCgroupDriverFromCRI feature gate
Signed-off-by: Peter Hunt <pehunt@redhat.com>
2025-07-24 12:37:14 -04:00
Peter Hunt
83a0d0c660 kubelet: add metric for version CRI implementation will lose support
Signed-off-by: Peter Hunt <pehunt@redhat.com>
2025-07-24 11:42:59 -04:00
Ania Borowiec
aecd37e6fb Moving Scheduler interfaces to staging: Move PodInfo and NodeInfo interfaces (together with related types) to staging repo, leaving internal implementation in kubernetes/kubernetes/pkg/scheduler 2025-07-24 12:10:58 +00:00
Patrick Ohly
24de875ceb DRA: graduate DynamicResourceAllocation feature to GA
It hasn't been on-by-default before, therefore it does not get locked to the
new default on yet. This has some impact on the scheduler configuration
because the plugin is now enabled by default.

Because the feature is now GA, it doesn't need to be a label on E2E tests,
which wouldn't be possible anyway once it gets removed entirely.
2025-07-24 08:33:56 +02:00
Patrick Ohly
21d929f599 integration: use --runtime-config-emulation-forward-compatible
Some tests do version emulation and need the DRA feature. In that combination
the --runtime-config-emulation-forward-compatible option is needed to allow
enabling the V1 API although it's only available in 1.34.
2025-07-24 08:33:56 +02:00
Patrick Ohly
5c4f81743c DRA: use v1 API
As before when adding v1beta2, DRA drivers built using the
k8s.io/dynamic-resource-allocation helper packages remain compatible with all
Kubernetes release >= 1.32. The helper code picks whatever API version is
enabled from v1beta1/v1beta2/v1.

However, the control plane now depends on v1, so a cluster configuration where
only v1beta1 or v1beta2 are enabled without the v1 won't work.
2025-07-24 08:33:45 +02:00
Patrick Ohly
cff91579e8 DRA API: v1 registration + tests 2025-07-24 08:30:25 +02:00
Kubernetes Prow Robot
c41cc0a144 Merge pull request #129837 from danwinship/aggregated-apiserver-endpointslices
Port aggregated apiserver discovery to EndpointSlices
2025-07-23 10:30:28 -07:00
Dan Winship
d70e7e223c Port aggregated apiserver discovery to EndpointSlices
Co-Authored-by: Jordan Liggitt <liggitt@google.com>
2025-07-23 11:07:29 -04:00
Kubernetes Prow Robot
ce9ba81802 Merge pull request #133059 from danwinship/node-manager
kube-proxy node manager (take 2)
2025-07-21 20:36:27 -07:00
Kubernetes Prow Robot
cc674e7470 Merge pull request #128010 from ahmedtd/pod-certificates-types
Pod Certificates: Preliminary implementation of KEP-4317
2025-07-21 19:26:30 -07:00
Alay Patel
a5b9c7a798 bump resource claim controller concurrent syncs to 50
Signed-off-by: Alay Patel <alayp@nvidia.com>
2025-07-21 17:57:57 -04:00
Taahir Ahmed
4624cb9bb9 Pod Certificates: Basic implementation
* Define feature gate
* Define and serve PodCertificateRequest
* Implement Kubelet projected volume source
* kube-controller-manager GCs PodCertificateRequests
* Add agnhost subcommand that implements a toy signer for testing

Change-Id: Id7ed030d449806410a4fa28aab0f2ce4e01d3b10
2025-07-21 21:49:57 +00:00
Kubernetes Prow Robot
0170df6f21 Merge pull request #133108 from SergeyKanzhelev/deleteSandBoxImageOption
pod sandbox image is not being used by kubelet any longer
2025-07-21 14:15:17 -07:00
Daman Arora
0dc51b16f9 kube-proxy: merge NodeEligibleHandler with NodeManager
ProxyHealthServer now consumes NodeManager to get the latest
updated node object for determining node eligibility.

Signed-off-by: Daman Arora <aroradaman@gmail.com>
Co-authored-by: Dan Winship <danwinship@redhat.com>
2025-07-21 17:00:44 -04:00
Daman Arora
d4892fef76 kube-proxy: merge NodePodCIDRHandler with NodeManager
NodeManager, if configured with to watch for PodCIDR watch, watches
for changes in PodCIDRs and crashes kube-proxy if a change is
detected in PodCIDRs.

Signed-off-by: Daman Arora <aroradaman@gmail.com>
Co-authored-by: Dan Winship <danwinship@redhat.com>
2025-07-21 17:00:44 -04:00
Daman Arora
373fb487f6 kube-proxy: add NodeManager to manage life-cycle based on NodeIPs
NodeManager initialises node informers, waits for cache sync and polls for
node object to retrieve NodeIPs, handle node events and crashes kube-proxy
when change in NodeIPs is detected.

Signed-off-by: Daman Arora <aroradaman@gmail.com>
Co-authored-by: Dan Winship <danwinship@redhat.com>
2025-07-21 17:00:44 -04:00
Daman Arora
d21ca8674c kube-proxy: add NodeTopologyConfig for tracking topology labels
This simplifies how the proxier receives update for change in node
labels. Instead of passing the complete Node object we just pass
the proxy relevant topology labels extracted from the complete list
of labels, and the downstream event handlers will only be notified
when there are changes in topology labels.

Signed-off-by: Daman Arora <aroradaman@gmail.com>
2025-07-21 17:00:44 -04:00
Kubernetes Prow Robot
ae21e81ae7 Merge pull request #132704 from p0lyn0mial/upstream-enable-watchlist
Promote WatchList feature to Beta
2025-07-21 11:58:27 -07:00
Sergey Kanzhelev
6e77bff18b pod sandbox image is not being used by kubelet any longer 2025-07-21 18:51:07 +00:00
Kubernetes Prow Robot
7a6afe1ffe Merge pull request #131886 from togettoyou/cleanup-scheduler-server
handle stoppedCh and listenerStoppedCh returned by cc.SecureServing.Serve
2025-07-21 08:56:26 -07:00
Kubernetes Prow Robot
ba35c0613d Merge pull request #132427 from soma00333/kuberuntime-contextual-logging-1
feat(kubelet): migrate kuberuntime to contextual logging
2025-07-21 05:50:36 -07:00
Kubernetes Prow Robot
c44bf18b9b Merge pull request #130713 from ArkaSaha30/bump-pause-version
dependency: update pause version to registry.k8s.io/pause:3.10.1
2025-07-20 20:16:26 -07:00
soma00333
ab839c93ff feat(kubelet): migrate kuberuntime to contextual logging 2025-07-20 09:47:50 +09:00
soma00333
7ddb042626 feat(cmd/kubelet): support structured and contextual logging 2025-07-19 17:10:37 +09:00
Kubernetes Prow Robot
5e83b9c2c2 Merge pull request #129942 from bart0sh/PR171-migrate-some-kubelet-components-to-contextual-logging
Migrate kubelet/{apis,kubeletconfig,nodeshutdown,pod,preemption} to contextual logging
2025-07-18 20:28:25 -07:00
Lukasz Szaszkiewicz
db342010f4 kube-controller-manager: enable WatchListClient 2025-07-17 12:08:03 +02:00
carlory
cef9f9edb6 kubeadm: fix a bug where it should generate default etcd command based on etcd version when the etcd image tag supports semver 2025-07-17 16:58:58 +08:00