Newer
Older
#cloud-config
# SSH config
no_ssh_fingerprints: false
ssh:
emit_keys_to_console: false
# update and upgrade instance
package_update: true
package_upgrade: true
# files to be created on the system
write_files:
- path: /etc/fstab
permissions: "0644"
owner: root:root
content: |
taiga-nfs.ncsa.illinois.edu:/taiga/ncsa/radiant/${project_name}/${cluster_name} /taiga nfs defaults 0 0
append: true
- path: /etc/docker/daemon.json
permissions: "0644"
owner: root:root
content: |
{
"exec-opts": ["native.cgroupdriver=systemd"],
"log-driver": "json-file",
"log-opts": {
"max-size": "100m"
},
"storage-driver": "overlay2"
}
- path: /usr/local/bin/rke1
permissions: "0700"
owner: root:root
content: |
#!/usr/bin/bash
echo "sleeping to wait for network"
while ! ping -c 1 -w 0 1.1.1.1 > /dev/null ; do echo "Sleep 10s"; sleep 10; done
if [ -e /usr/bin/yum ]; then
yum -y install iscsi-initiator-utils nfs-utils
elif [ -e /usr/bin/apt ]; then
apt install -y open-iscsi nfs-common
else
echo "Don't know how to install iscsi/nfs"
fi
curl https://releases.rancher.com/install-docker/24.0.sh | sh
${node_command} ${node_options} ${node_labels}
echo "all done"
# run this command once the system is booted
runcmd:
- /usr/local/bin/rke1