afbjorklund / buildroot4kubernetes

Minimal linux distribution for running kubernetes ("boot2kubeadm")

Home Page:

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool


Build a minimal environment with Buildroot, enough for running kubeadm for Kubernetes.

So basically the "bigger brother" of boot2docker... Or a smaller version of minikube.iso.

Interface Implementation Notes
Container Runtime docker cri-dockerd*
Container Networking flannel VXLAN backend
Container Storage nfs ReadWriteMany

* Needed for Kubernetes 1.24 and later only

Written by Anders Björklund (@afbjorklund)


  • namespaces
  • cgroups
  • overlayfs
  • nat
  • bridge
  • conntrack
  • vxlan


  • systemd
  • glibc (required by systemd)
  • docker
  • containerd (required by dockerd)
  • bash
  • iptables
  • conntrack (required since 1.18)

graph size

Bootable image:


176M	output/disk.img.gz

Flashable image:


174M	output/

Kubernetes bin:

43M	/usr/bin/kubeadm
44M	/usr/bin/kubectl
111M	/usr/bin/kubelet

Required images:

$ kubeadm config images list

docker images:


REPOSITORY                           TAG        IMAGE ID       CREATED         SIZE            v1.24.0    529072250ccc   29 hours ago    130MB                v1.24.0    77b49675beae   29 hours ago    110MB            v1.24.0    e3ed7dee73e9   29 hours ago    51MB   v1.24.0    88784fb4ac2f   29 hours ago    119MB                     3.7        221177c6082a   7 weeks ago     711kB                      3.5.3-0    aebe758cef4c   2 weeks ago     299MB           v1.8.6     a4ca41631cc7   6 months ago    46.8MB                     3.6        6270bb605e12   9 months ago    683kB
flannelcni/flannel                   v0.17.0    9247abf08677   2 months ago    59.8MB


REPOSITORY                           TAG        IMAGE ID       CREATED         SIZE            v1.24.0    b62a103951f4   2 weeks ago     126MB                v1.24.0    66e1443684b0   2 weeks ago     106MB            v1.24.0    b81513b3bfb4   2 weeks ago     50MB   v1.24.0    59fad34d4fe0   2 weeks ago     116MB                     3.7        e5a475a03805   2 months ago    514kB                      3.5.3-0    a9a710bb96df   5 weeks ago     178MB           v1.8.6     edaa71f2aee8   7 months ago    46.8MB                     3.6        7d46a07936af   9 months ago    484kB
flannelcni/flannel                   v0.17.0    a8fbfb17608d   2 months ago    61.8MB

image size

docker pull (gzip):

32M	images/
37M	images/
15M	images/
29M	images/
292K	images/
97M	images/
13M	images/
19M	images/
240M	total

docker save | xz:

166M	images.txz
Strms  Blocks   Compressed Uncompressed  Ratio  Check   Filename
    1      50    165.4 MiB    776.0 MiB  0.213  CRC32   images.txz

Device layout:

QEMU File Media Device Used for Size
-hda disk.img disk /dev/sda Persistent /var 20g
-hdb data.img disk /dev/sdb Persistent /data 5g
-hdc buildroot.iso cdrom Buildroot booting 137m
-hdd images.iso cdrom /dev/sdc Kubernetes images 160m

Reference board:

pc (bios)

4.9M	output/images/bzImage
84M	output/images/rootfs.ext2


18M    output/images/boot.vfat
75M    output/images/rootfs.ext4
ezoic increase your site revenue


Minimal linux distribution for running kubernetes ("boot2kubeadm")


Language:Makefile 70.2%Language:Python 22.8%Language:Shell 7.1%