27 lines
624 B
Bash
Executable file
27 lines
624 B
Bash
Executable file
#!/bin/sh
|
|
|
|
BASE_CMD="ansible-playbook playbook.yml --ask-vault-pass"
|
|
|
|
echo "Installing community modules"
|
|
ansible-galaxy collection install community.general
|
|
|
|
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
|
|
else
|
|
echo "Deploying services: $2"
|
|
$BASE_CMD --tags setup_services --extra-vars "services=$2"
|
|
fi
|
|
;;
|
|
"base")
|
|
$BASE_CMD --tags base_only
|
|
;;
|
|
esac
|
|
fi
|