Fix brainfart of disabling SSH and then SSH'ing over to poweroff.

This commit is contained in:
Jarno Rantanen 2020-03-13 10:22:37 +02:00
parent c3ef0c9d6e
commit a8997d59b4

View File

@ -251,11 +251,8 @@ rm temp
working "Removing SSH host keys & enable regeneration" working "Removing SSH host keys & enable regeneration"
ssh "sudo rm -f -v /etc/ssh/ssh_host_*_key* && sudo systemctl enable regenerate_ssh_host_keys" ssh "sudo rm -f -v /etc/ssh/ssh_host_*_key* && sudo systemctl enable regenerate_ssh_host_keys"
working "Removing temporary SSH pubkey & disabling SSH" working "Removing temporary SSH pubkey & disabling SSH & shutting down"
ssh "(echo > .ssh/authorized_keys) && sudo systemctl disable ssh" ssh "(echo > .ssh/authorized_keys) && sudo systemctl disable ssh && sudo nohup poweroff"
working "Powering off the Pi"
ssh "sudo poweroff"
question "Eject the SD card from the Pi, and mount it back to this computer" question "Eject the SD card from the Pi, and mount it back to this computer"
echo "(press enter when ready)" echo "(press enter when ready)"