add install-kubelet.sh script

This commit is contained in:
Steven Polley 2023-12-17 18:10:56 -07:00
parent 8b0ad90981
commit 925ff4e71c
6 changed files with 33 additions and 3 deletions

View File

@ -47,6 +47,16 @@ storage:
inline: | inline: |
net.bridge.bridge-nf-call-iptables=1 net.bridge.bridge-nf-call-iptables=1
net.ipv4.ip_forward=1 net.ipv4.ip_forward=1
# script to install kubelet dependencies
- path: /usr/local/bin/install-kubelet.sh
mode: 0744
overwrite: true
contents:
inline: |
#!/bin/bash
rpm-ostree install kubelet kubeadm kubectl cri-o
systemctl enable crio kubelet
systemctl reboot
passwd: # setting login credentials passwd: # setting login credentials
users: users:
- name: steven - name: steven

View File

@ -47,6 +47,16 @@ storage:
inline: | inline: |
net.bridge.bridge-nf-call-iptables=1 net.bridge.bridge-nf-call-iptables=1
net.ipv4.ip_forward=1 net.ipv4.ip_forward=1
# script to install kubelet dependencies
- path: /usr/local/bin/install-kubelet.sh
mode: 0744
overwrite: true
contents:
inline: |
#!/bin/bash
rpm-ostree install kubelet kubeadm kubectl cri-o
systemctl enable crio kubelet
systemctl reboot
passwd: # setting login credentials passwd: # setting login credentials
users: users:
- name: steven - name: steven

View File

@ -47,6 +47,16 @@ storage:
inline: | inline: |
net.bridge.bridge-nf-call-iptables=1 net.bridge.bridge-nf-call-iptables=1
net.ipv4.ip_forward=1 net.ipv4.ip_forward=1
# script to install kubelet dependencies
- path: /usr/local/bin/install-kubelet.sh
mode: 0744
overwrite: true
contents:
inline: |
#!/bin/bash
rpm-ostree install kubelet kubeadm kubectl cri-o
systemctl enable crio kubelet
systemctl reboot
passwd: # setting login credentials passwd: # setting login credentials
users: users:
- name: steven - name: steven

View File

@ -1 +1 @@
{"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node01%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}} {"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node01%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420},{"overwrite":true,"path":"/usr/local/bin/install-kubelet.sh","contents":{"compression":"","source":"data:,%23!%2Fbin%2Fbash%0Arpm-ostree%20install%20kubelet%20kubeadm%20kubectl%20cri-o%0Asystemctl%20enable%20crio%20kubelet%0Asystemctl%20reboot%0A"},"mode":484}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}}

View File

@ -1 +1 @@
{"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node02%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}} {"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node02%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420},{"overwrite":true,"path":"/usr/local/bin/install-kubelet.sh","contents":{"compression":"","source":"data:,%23!%2Fbin%2Fbash%0Arpm-ostree%20install%20kubelet%20kubeadm%20kubectl%20cri-o%0Asystemctl%20enable%20crio%20kubelet%0Asystemctl%20reboot%0A"},"mode":484}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}}

View File

@ -1 +1 @@
{"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node03%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}} {"ignition":{"version":"3.4.0"},"passwd":{"users":[{"groups":["sudo","docker"],"name":"steven","sshAuthorizedKeys":["ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAsPq55j525p1ntk37oeel83i6FVm9+ptWk/4csqZivKRrtfhSebtWj0GHg7mnN+XIvQFEXY1HuPSfAByuwURN7LrBTKYNDHM5VxyHSP3s6Ik9OYngbVDCcDRc94teivYalYPyC5rCfIFYRg+vrxD1Gl7eASpiS7z2YD5w6WSxEnQ9tk+GQgsbRcsDBpKTZL/yHZbNNOamUwv3FNmaDpq7V8d1IrKCQiivYQ5n/sWpQnOzMOnY5i7OKr2G56KbaVIXRe3JKIF7ifAK0aJ5q+45RmwdgVh+SgwIFBzQD4GZJbr8jbvxYO9NjbF9fm7qLYnbHNyT7cDx8ClQqAz/2cL0xw== taterwin10"]}]},"storage":{"files":[{"overwrite":true,"path":"/etc/hostname","contents":{"compression":"","source":"data:,kube-node03%0A"},"mode":420},{"overwrite":true,"path":"/etc/dnf/modules.d/cri-o.module","contents":{"compression":"","source":"data:,%5Bcri-o%5D%0Aname%3Dcri-o%0Astream%3D1.17%0Aprofiles%3D%0Astate%3Denabled%0A"},"mode":420},{"overwrite":true,"path":"/etc/yum.repos.d/kubernetes.repo","contents":{"compression":"gzip","source":"data:;base64,H4sIAAAAAAAC/5TMPa7CMBDE8X4P41Ve9YjkE3AEhJCTjBy0/lh5HURuj0KBaOlm/sXvItuEVtBhVyohw58/gaZg2Frya+9qI7NKNCf/5u6V59owsvUwJYz8GNzfiZtmJpQjLX6gqHFeMYsfqEHr7etHjYL9J/ggltDDe+TFPXNygp1eAQAA//9ze8vVwgAAAA=="},"mode":420},{"overwrite":true,"path":"/etc/modules-load.d/br_netfilter.conf","contents":{"compression":"","source":"data:,br_netfilter"},"mode":420},{"overwrite":true,"path":"/etc/sysctl.d/kubernetes.conf","contents":{"compression":"","source":"data:,net.bridge.bridge-nf-call-iptables%3D1%0Anet.ipv4.ip_forward%3D1%0A"},"mode":420},{"overwrite":true,"path":"/usr/local/bin/install-kubelet.sh","contents":{"compression":"","source":"data:,%23!%2Fbin%2Fbash%0Arpm-ostree%20install%20kubelet%20kubeadm%20kubectl%20cri-o%0Asystemctl%20enable%20crio%20kubelet%0Asystemctl%20reboot%0A"},"mode":484}]},"systemd":{"units":[{"contents":"[Unit]\nBefore=systemd-user-sessions.service\nWants=network-online.target\nAfter=network-online.target\nConditionPathExists=!/var/lib/install-kubelet\n\n[Service]\nType=oneshot\nExecStart=/usr/local/bin/install-kubelet.sh\nExecStartPost=/usr/bin/touch /var/lib/install-kubelet\nRemainAfterExit=yes\n\n[Install]\nWantedBy=multi-user.target\n","enabled":true,"name":"install-kubelet.service"}]}}