From the ISO

Use the ISO when you have a bare machine or a VM with no operating system or Kubernetes on it. The ISO is the Gingko OS: Kairos on Alpine, with k3s and the platform chart already in it. It installs to a disk, reboots, and starts the platform by itself.

Get the ISO

The ISO is published as a one-layer image, so any registry client can fetch it. Set v to a published OS version:

v=<version>
crane export pkg.gingko.garden/os/gingko-iso:$v - | tar -x gingko.iso

Write gingko.iso to the boot medium and boot the machine from it. The repository does not script that step.

Give it a cloud-config

The install is driven by a cloud-config. Kairos reads it the usual ways, for example from a NoCloud CD or from a config_url= boot argument. It only has to say where the system goes and who logs in:

#cloud-config
install:
  device: /dev/sda
  auto: true
  reboot: true
users:
  - name: kairos
    ssh_authorized_keys: [github:<you>]

install.device is the disk the system is written to, so use a disk you are willing to erase. The machine installs, reboots, starts k3s and the newest platform chart. Disks other than the system one are left for the setup wizard's storage step.

In a VM

The ISO installs a VM the same way. Attach gingko.iso as a CD and the cloud-config as a NoCloud drive. Use BIOS firmware, and put the system disk on SATA rather than virtio-scsi: SeaBIOS does not boot the installed disk from virtio-scsi.

A VM boots the CD again if the CD is still attached, and installs again. So in the cloud-config, use poweroff: true in place of reboot: true, then detach the CD and start the VM.

Keep a ZFS pool across reboots

The OS imports no pool by itself. To use a pool for app data, name it in the cloud-config, and the OS imports it at each boot before k3s starts:

stages:
  initramfs:
    - files:
        - path: /etc/conf.d/gingko-pool
          content: pool=tank

If the pool does not import, k3s does not start. Datasets in the pool can hold what the system disk would otherwise write. Set these when the system disk is small or slow, for example an SD card:

Mountpoint Holds
/var/lib/rancher the cluster's state and the container images
/var/lib/kubelet the pods' volumes and the kubelet's state
/var/lib/cni the network's per-pod records
/var/log every log, the pods' logs included
zfs create -u -o mountpoint=/var/log tank/log

The system disk is then written only by an OS upgrade and by changes to /etc.

In a VM, pass the pool's disks or their controller through to it. The host must not import the pool: only one system can. When the host still sees the disks, run zpool set multihost=on <pool> on it before you export the pool. The pool then refuses a second import while the VM holds it.

Open the setup wizard

Forward the backend to your machine:

kubectl -n sys-backend port-forward deploy/gko-backend 8080:8081

Open http://localhost:8080. The wizard asks for storage and for the domain whose DNS records you prepared in Prerequisites.


Last validated: · View as Markdown