mirror of
https://github.com/trailofbits/algo
synced 2024-11-04 06:00:21 +00:00
25513cf925
* Refactoring, Linting and additional tests * Vultr: Undefined variable and deprecation notes fix * Travis-CI enable linters * Azure: Update python requirements * Update main.yml * Update install.sh * Add missing roles to ansible-lint * Linting for skipped roles * add .ansible-lint config
24 lines
549 B
Bash
Executable File
24 lines
549 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
|
|
if [ -z ${VIRTUAL_ENV+x} ]
|
|
then
|
|
ACTIVATE_SCRIPT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/env/bin/activate"
|
|
if [ -f "$ACTIVATE_SCRIPT" ]
|
|
then
|
|
# shellcheck source=/dev/null
|
|
source "$ACTIVATE_SCRIPT"
|
|
else
|
|
echo "$ACTIVATE_SCRIPT not found. Did you follow documentation to install dependencies?"
|
|
exit 1
|
|
fi
|
|
fi
|
|
|
|
case "$1" in
|
|
update-users) PLAYBOOK=users.yml; ARGS=( "${@:2}" -t update-users ) ;;
|
|
*) PLAYBOOK=main.yml; ARGS=( "${@}" ) ;;
|
|
esac
|
|
|
|
ansible-playbook ${PLAYBOOK} "${ARGS[@]}"
|