kubernetes-sigs/kubespray

k8s-certs-renew renews certs every month

開放

#13,072 建立於 2026年3月3日

 (6 則留言) (0 個反應) (1 位負責人)HTML (4,419 個分叉)batch import
Ubuntu 24help wantedkind/bug

倉庫指標

星標
 (10,380 顆星)
PR 合併指標
 (平均合併 25天) (30 天內合併 26 個 PR)

描述

What happened?

When k8s-certs-renew is running, next_time is emtpy, causing the certs renewed directly, effectively renews the certs every month.

Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985557]: ++ systemctl show k8s-certs-renew.timer -p NextElapseUSecRealtime --value
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: + next_time=
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: + '[' '' == '' ']'
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: + echo '## Skip expiry comparison due to fail to parse next elapse from systemd calendar,do renewal directly ##'
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: ## Skip expiry comparison due to fail to parse next elapse from systemd calendar,do renewal directly ##
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: + echo '## Renewing certificates managed by kubeadm ##'
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: ## Renewing certificates managed by kubeadm ##
Mar 03 10:13:11 master1 k8s-certs-renew.sh[1985529]: + /usr/local/bin/kubeadm certs renew all

I dumped all the properties of the timer ink8s-certs-renew.sh, it seems there's no NextElapseUSecRealtime when timer is active. timer-values.txt

What did you expect to happen?

only renew certs when necessary

How can we reproduce it (as minimally and precisely as possible)?

1

OS

Ubuntu 24

Version of Ansible

all supported versions

Version of Python

all supported versions

Version of Kubespray (commit)

v2.30.0

Network plugin used

custom_cni

Full inventory with variables

1

Command used to invoke ansible

1

Output of ansible run

1

Anything else we need to know

No response

貢獻者指南