projects
/
noc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ctf has been moved
[noc.git]
/
ansible
/
vm-install.sh
diff --git
a/ansible/vm-install.sh
b/ansible/vm-install.sh
index
47291ed
..
4e93d2c
100755
(executable)
--- a/
ansible/vm-install.sh
+++ b/
ansible/vm-install.sh
@@
-1,7
+1,7
@@
#!/bin/bash
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]; then
#!/bin/bash
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]; then
- echo "$0 <vm> <distro> <codename>"
+ echo "$0 <hostname> <distro> <codename>"
exit 1
fi
exit 1
fi
@@
-12,8
+12,8
@@
shift
codename=$1
shift
codename=$1
shift
-echo "installing vm: $name with $distro/$codename"
+echo "installing $name with $distro/$codename"
echo ""
echo "######## running the install playbook ########"
echo ""
echo "######## running the install playbook ########"
-exec ansible-playbook -e "hostname=$name" -e "distro=$distro" -e "distcodename=$codename" $@ vm-install.yml
+exec ansible-playbook -e "hostname=$name" -e "install_distro=$distro" -e "install_codename=$codename" $@ $(basename "$0" .sh).yml