10 lines
203 B
Bash
Executable file
10 lines
203 B
Bash
Executable file
#!/bin/bash
|
|
if [ ! -f "$1" ]; then
|
|
echo "error: must specify rooms file"
|
|
exit 1
|
|
fi
|
|
NUM=0
|
|
for HOST in `cat "$1"`; do
|
|
>&2 echo stopping host $HOST
|
|
ssh pi@$HOST "screen -X quit && sudo reboot"
|
|
done
|