You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
670 B

  1. #!/bin/bash
  2. set -euxo pipefail
  3. : ${ANSIBLE_MAJOR_VERSION:=2.10}
  4. /usr/bin/python -m pip uninstall -y ansible ansible-base ansible-core
  5. /usr/bin/python -m pip install -r tests/requirements-${ANSIBLE_MAJOR_VERSION}.txt
  6. mkdir -p /.ssh
  7. mkdir -p cluster-dump
  8. mkdir -p $HOME/.ssh
  9. ansible-playbook --version
  10. # in some cases we may need to bring in collections or roles from ansible-galaxy
  11. # to compensate for missing functionality in older ansible versions
  12. if [ -f requirements-${ANSIBLE_MAJOR_VERSION}.yml ] ; then
  13. ansible-galaxy role install -r requirements-${ANSIBLE_MAJOR_VERSION}.yml
  14. ansible-galaxy collection install -r requirements-${ANSIBLE_MAJOR_VERSION}.yml
  15. fi