Skip to content

Commit

Permalink
Update k8s-certs-renew.sh.j2 (#7422)
Browse files Browse the repository at this point in the history
fix undefinedElse

(cherry picked from commit cce9d31)
  • Loading branch information
hjanuschka authored and k8s-ci-robot committed Apr 21, 2021
1 parent 58b9265 commit 45a92e4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions roles/kubernetes/master/templates/k8s-certs-renew.sh.j2
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#!/bin/bash

echo "## Expiration before renewal ##"
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') }}certs check-expiration
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') else '' }}certs check-expiration

echo "## Renewing certificates managed by kubeadm ##"
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') }}certs renew all
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') else '' }}certs renew all

echo "## Restarting control plane pods managed by kubeadm ##"
{% if container_manager == "docker" %}
Expand All @@ -20,4 +20,4 @@ echo "## Waiting for apiserver to be up again ##"
until printf "" 2>>/dev/null >>/dev/tcp/127.0.0.1/6443; do sleep 1; done

echo "## Expiration after renewal ##"
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') }}certs check-expiration
{{ bin_dir }}/kubeadm {{ 'alpha ' if kube_version is version('v1.20.0', '<') else '' }}certs check-expiration

0 comments on commit 45a92e4

Please sign in to comment.