variant: flatcar version: 1.1.0 systemd: units: - name: k3s-install.service enabled: true contents: | [Unit] Description=Run K3s script Wants = network-online.target After = network.target network-online.target ConditionPathExists=/opt/k3s-install.sh ConditionPathExists=!/opt/bin/k3s [Service] Type=forking TimeoutStartSec=180 RemainAfterExit=yes KillMode=process Environment="K3S_URL=https://172.23.2.10:6443" Environment="K3S_TOKEN=${k3s_token}" Environment="INSTALL_K3S_VERSION=${k3s_version}" Environment="INSTALL_K3S_EXEC=agent --node-ip=${node_ip} --kubelet-arg --cloud-provider=external --node-label k8s.icb4dc0.de/storage-node=${tostring(storage_node)}" ExecStart=/usr/bin/sh -c "/opt/k3s-install.sh" [Install] WantedBy=multi-user.target storage: files: - path: /etc/hostname mode: 0644 contents: inline: ${host} - path: /opt/k3s-install.sh mode: 0777 contents: source: https://get.k3s.io