forked from data.coop/ansible
20 lines
516 B
Bash
Executable file
20 lines
516 B
Bash
Executable file
#!/bin/sh
|
|
|
|
BASE_CMD="ansible-playbook playbook.yml -i datacoop_hosts --ask-vault-pass"
|
|
|
|
if [ -z "$1" ]; then
|
|
echo "Deploying all!"
|
|
$BASE_CMD
|
|
else
|
|
case $1 in
|
|
"services")
|
|
if [ -z "$2" ]; then
|
|
echo "Deploying all services!"
|
|
$BASE_CMD --tags setup_services --ask-vault-pass
|
|
else
|
|
echo "Deploying services: $2"
|
|
$BASE_CMD --tags setup_services --ask-vault-pass --extra-vars "services=$2"
|
|
fi
|
|
esac
|
|
fi
|