Skip to content

Commit

Permalink
Fix SELinux race condition on non-bootstrap controllers in multi-cont…
Browse files Browse the repository at this point in the history
…roller (poseidon#808)

* Fix race condition for bootstrap-secrets SELinux context on non-bootstrap controllers in multi-controller FCOS clusters
* On first boot from disk on non-bootstrap controllers, adding bootstrap-secrets races with kubelet.service starting, which can cause the secrets assets to have the wrong label until kubelet.service restarts (service, reboot, auto-update)
* This can manifest as `kube-apiserver`, `kube-controller-manager`, and `kube-scheduler` pods crashlooping on spare controllers on first cluster creation
  • Loading branch information
beyondbill authored Aug 20, 2020
1 parent 2cae213 commit 2160906
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fedora-coreos/kubernetes/fcc/controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ storage:
mv manifests /opt/bootstrap/assets/manifests
mv manifests-networking/* /opt/bootstrap/assets/manifests/
rm -rf assets auth static-manifests tls manifests-networking
chcon -R -u system_u -t container_file_t /etc/kubernetes/bootstrap-secrets
- path: /opt/bootstrap/apply
mode: 0544
contents:
Expand Down

0 comments on commit 2160906

Please sign in to comment.