Skip to content

Commit

Permalink
Fix kubelet not upgraded automatically (regression from 1230) (#1267)
Browse files Browse the repository at this point in the history
  • Loading branch information
jakolehm authored Apr 4, 2019
1 parent 5ae8fd7 commit b38beb2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions lib/pharos/host/debian/scripts/install-kube-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
set -e

export DEBIAN_FRONTEND=noninteractive
apt-mark unhold kubectl kubeadm || echo "Nothing to unhold"
apt-get install -y "kubectl=${KUBE_VERSION}-00" "kubeadm=${KUBEADM_VERSION}-00"
apt-mark hold kubectl kubeadm
apt-mark unhold kubelet kubectl kubeadm || echo "Nothing to unhold"
apt-get install -y "kubelet=${KUBE_VERSION}-00" "kubectl=${KUBE_VERSION}-00" "kubeadm=${KUBEADM_VERSION}-00"
apt-mark hold kubelet kubectl kubeadm

# use KUBELET_EXTRA_ARGS from /etc/systemd/system/kubelet.service.d/11-pharos.conf instead
sed -i 's/^KUBELET_EXTRA_ARGS=/#\0/' /etc/default/kubelet
Expand Down
1 change: 1 addition & 0 deletions lib/pharos/host/el7/scripts/install-kube-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

set -e

yum_install_with_lock "kubelet" "$KUBE_VERSION"
yum_install_with_lock "kubectl" "$KUBE_VERSION"
yum_install_with_lock "kubeadm" "$KUBE_VERSION"

Expand Down
6 changes: 3 additions & 3 deletions lib/pharos/host/ubuntu/scripts/install-kube-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
set -e

export DEBIAN_FRONTEND=noninteractive
apt-mark unhold kubectl kubeadm || echo "Nothing to unhold"
apt-get install -y "kubectl=${KUBE_VERSION}-00" "kubeadm=${KUBEADM_VERSION}-00"
apt-mark hold kubectl kubeadm
apt-mark unhold kubelet kubectl kubeadm || echo "Nothing to unhold"
apt-get install -y "kubelet=${KUBE_VERSION}-00" "kubectl=${KUBE_VERSION}-00" "kubeadm=${KUBEADM_VERSION}-00"
apt-mark hold kubelet kubectl kubeadm

# use KUBELET_EXTRA_ARGS from /etc/systemd/system/kubelet.service.d/11-pharos.conf instead
sed -i 's/^KUBELET_EXTRA_ARGS=/#\0/' /etc/default/kubelet
Expand Down

0 comments on commit b38beb2

Please sign in to comment.