From d2a719af43ed7e200e2e79619ce46625530dddec Mon Sep 17 00:00:00 2001 From: rasmus Date: Tue, 3 Jan 2023 16:09:17 +0000 Subject: [PATCH] README: Improve cluster formation docs - Begin code block with sudo to remind the following shall be ran as root. - Remove hardcoded key, instead copy from ubutnu user. --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 794d867..0e8cef3 100644 --- a/README.md +++ b/README.md @@ -161,6 +161,8 @@ Added some ARM64 workers by using Ubuntu 22.04 server on Raspberry Pi. After machines have booted up and you can reach them via SSH: ```bash +sudo -i + # Enable required kernel modules cat > /etc/modules << EOF overlay @@ -200,10 +202,8 @@ systemctl disable --now multipathd snapd bluetooth ModemManager hciuart wpa_supp # Permit root login sed -i -e 's/PermitRootLogin no/PermitRootLogin without-password/' /etc/ssh/sshd_config systemctl reload ssh -cat << EOF > /root/.ssh/authorized_keys -sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBD4/e9SWYWYoNZMkkF+NirhbmHuUgjoCap42kAq0pLIXFwIqgVTCre03VPoChIwBClc8RspLKqr5W3j0fG8QwnQAAAAEc3NoOg== lauri@lauri-x13 -EOF -userdel -f ubuntu +cat ~ubuntu/.ssh/authorized_keys > /root/.ssh/authorized_keys +userdel -fr ubuntu apt-get install -yqq linux-image-generic apt-get remove -yq cloud-init linux-image-*-kvm ```