NOTE: This codebase has been deprecated in favour of CoreOS's official operator.
A Kubernetes operator that manages the reboot cycle for CoreOS nodes. Normally when a node self-updates, it waits to be rebooted in order for the changes to be effected. This has been traditionally done either by manual intervention or by sync tools like locksmith. Although the latter works very well, it does not offer full programmatic extensibility that's needed by some orgs who require high availability for their Kubernetes clusters.
This project was inspired by Aaron Levy's KubeCon talk and is heavily based on his demo controller repository. Although this project has been verified to work, it's still very much in alpha so it's advised to use this in dev environments only.
The operator is composed of two components: the
controller which synchronizes the reboots, ensuring that the cluster will not be negatively impacted; and the
agent DaemonSet, which listens out for reboot requests on systemd and performs the reboot itself.
This is the lifecycle of a reboot:
systemctl stop locksmithd
# Create reboot-operator ns kubectl create -f manifests/namespace.yaml # Create cluster roles and sa bindings kubectl create -f manifests/cluster-role.yaml # Create controller RS kubectl create -f manifests/reboot-controller.yaml # Create agent DS kubectl create -f manifests/cluster-role.yaml
Build agent and controller binaries:
make clean all
Build agent and controller Docker images:
make clean images