X-Git-Url: https://git.phdru.name/?a=blobdiff_plain;ds=sidebyside;f=playbooks%2Fdebian-init-system.sh;h=d53c6a55c38c50c2e84376515106770adfdcb3ae;hb=22bc79da34fa1c31800f522577d85141ca139140;hp=8655c7293f149adf7946a64776b873881217110c;hpb=f4436893f15c153a266daf92f1d6a928f9927e02;p=ansible.git diff --git a/playbooks/debian-init-system.sh b/playbooks/debian-init-system.sh index 8655c72..d53c6a5 100755 --- a/playbooks/debian-init-system.sh +++ b/playbooks/debian-init-system.sh @@ -1,8 +1,17 @@ #! /bin/sh +if [ -z "$1" ]; then + echo "Usage: $0 host" >&2 + exit 1 +fi + +host="$1" +shift + cd "`dirname \"$0\"`" && # Passwordless access isn't configured yet; use `ssh` connection sharing. # `sudo` isn't configured yet too; use `su` and ask for root password. -ansible-playbook debian/init-system.yml "$@" --become-method=su -K && -exec ./run-role debian/remove-systemd "$@" +ansible-playbook debian/init-system.yml "$@" -e hosts="$host" \ + --become-method=su -K && +exec ansible-playbook debian/init-system2.yml "$@" -e hosts="$host"