add data protection information to subscribeack
[ansible.git] / do-update
1 #!/bin/bash
2 cd "$(dirname "$(readlink -e "$0")")"
3 for HOST in "$@"; do
4   echo "Playing on $HOST"
5   ansible-playbook upgrade.yml -l "$HOST"
6   read -p "Do you want me to reboot? (y/N) " ANSWER
7   if [[ "$ANSWER" == y* ]]; then
8     ansible "$HOST" -a "shutdown -r +1"
9   fi
10   echo
11 done