I'd like to install a CI tool on GKE so I can run docker-in-docker via Sysbox.
In order to do that, I need to install the Sysbox container runtime.
Is it possible to do that in GKE?
GKE
is a provider-managed Kubernetes solution where certain aspects are handled by your cloud provider. Things like nodes provisioning, automatic updates, security patching, access to certain storage solutions out of the box, etc.
Focusing specifically on Nodes
. Kubernetes relies on Container Runtime
to run it's containers. GKE
has predefined images with specific Container Runtimes
. You can see by below table:
OS Node images Container-Optimized OS Container-Optimized OS with Containerd (cos_containerd), Container-Optimized OS with Docker (cos) Ubuntu Ubuntu with Containerd (ubuntu_containerd), Ubuntu with Docker (ubuntu) Windows Server Windows Server LTSC (windows_ltsc), Windows Server SAC (windows_sac) -- Cloud.google.com: Kubernetes Engine: Docs: Concepts: Node images
As you can see the Container Runtimes
are already predetermined. There are differences between the OS
's which are prepared to run within GKE
ecosystem. For example, COS
does not have an inherent package manager (for that you should use CoreOS Toolbox).
Adding to that:
Node VM modifications
Modifications on the boot disk of a node VM do not persist across node re-creations. Nodes are re-created during manual upgrade, auto-upgrade, auto-repair, and auto-scaling. In addition, nodes are re-created when you enable a feature that requires node re-creation, such as GKE sandbox, intranode visibility, and shielded nodes.
To preserve modifications across node re-creation, use a DaemonSet.
It's not recommended to manage critical software provided by a node image, such as the kernel or container runtime (whether
containerd
ordocker
). Node images are tested extensively, and modifying critical software provided in the node image puts the node into an unknown and untestable state.-- Cloud.google.com: Kubernetes Engine: Docs: Concepts: Node images: Modifications
Additional resources: