deploy.sh check fait la --syntax-check et peut être utilisé avec l'argument local
This commit is contained in:
parent
c7c790e608
commit
49fa247792
20
deploy.sh
20
deploy.sh
|
@ -1,10 +1,14 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
if [[ $1 = "test" ]]; then
|
CMD="ansible-playbook -i hosts recette.yml"
|
||||||
ansible-playbook --check -i hosts recette.yml
|
|
||||||
elif [[ $1 = "local" ]]; then
|
for arg in "$@"; do
|
||||||
ansible-playbook --connection=local --inventory 127.0.0.1, --limit 127.0.0.1 \
|
if [[ $arg = "local" ]]; then
|
||||||
recette.yml -i hosts
|
CMD="$CMD --connection=local --inventory 127.0.0.1, --limit 127.0.0.1"
|
||||||
else
|
fi
|
||||||
ansible-playbook -i hosts recette.yml
|
if [[ $arg = "check" ]]; then
|
||||||
fi
|
CMD="$CMD --syntax-check"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
eval $CMD
|
||||||
|
|
Loading…
Reference in New Issue