nix-files/pkgs/additional/sane-scripts/src/sane-reboot

14 lines
197 B
Plaintext
Executable File

#!/usr/bin/env nix-shell
#!nix-shell -i bash -p systemd
target="$1"
host="$(hostname)"
if [ "$host" = "$target" ]
then
sudo reboot now
else
echo "WRONG MACHINE. you're on $host."
exit 1
fi