eb727f4a01
As of Ansible v2.2 all the missing modules bifrost requires are included in the pip-installable Ansible package. Let's allow then for a possiibility for bifrost to install Ansible directly from PyPI (into the system or in virtualenv) instead of from cloned source repo. This patsh first extracts the installation of binary/Python dependencies and installation of Ansible itself from the "env-setup.sh" script to two separate scripts "install-deps.sh" and "install-ansible-source.sh". It also adds a third script "install-ansible-pip.sh" that is called when environment variable ANSIBLE_FROM_PYPI is set to "True" (default is "False" for backward compatibility). It then looks up ANSIBLE_PIP_VERSION env variable (defaults to "2.2") and pip-installs Ansible of that given version strictly. Change-Id: Ia72e06d7bf127569d423fa521b8ddab87453809e
13 lines
261 B
Bash
Executable File
13 lines
261 B
Bash
Executable File
#!/bin/bash
|
|
set -eu
|
|
|
|
ANSIBLE_FROM_PYPI=${ANSIBLE_FROM_PYPI:-"False"}
|
|
|
|
source $(dirname $0)/install-deps.sh
|
|
|
|
if [[ "$ANSIBLE_FROM_PYPI" == "True" ]]; then
|
|
source $(dirname $0)/install-ansible-pip.sh
|
|
else
|
|
source $(dirname $0)/install-ansible-source.sh
|
|
fi
|