This role will install the boto
library via pip
. boto3
(the Python SDK recommended by Amazon AWS) is installed by default , while boto
(version 2) is not. Note that a number of number of Ansible modules are still using version 2.
pip
will be installed if absent, via the get-pip.py
script (default) or thru the OS package managers.
If using RedHat/CentOS, make sure you have the EPEL repository installed prior to using this role (you can install it using the geerlingguy.repo-epel
role).
aws_sdk_boto3_version
: Version ofboto3
to install. If this variable is not provided, pip will install the latest listed in PyPI.aws_sdk_boto_version
: Version ofboto
(version 2) to install. If this variable is not provided, pip will install the latest listed in PyPI.
aws_sdk_pip_use_package_manager: false
Pip will be installed using the get-pip.py
script. If set to true
, pip will install using apt (Debian) or yum (Red Hat).
aws_sdk_install_boto: false
aws_sdk_install_boto3: true
By default, boto3
will be installed but boto
(version 2) will not. Most ansible modules are still using boto
but not boto3
.
aws_sdk_pip_script_url: https://bootstrap.pypa.io/get-pip.py
aws_sdk_tmp_script_path: /tmp/get-pip.py
aws_sdk_apt_cache_valid_time: 300 # Skip apt update if cache is less than 5 min.
None
- hosts: all
roles:
- gametize.aws-sdk
Travis tests (.travis.yml
) are set up according to this article by geerlingguy.
Gitlab CI tests are set up similarly, but with more details. Tests can be run with gitlab-runner. Example of running this locally:
gitlab-ci-multi-runner exec shell test_centos7
MIT
LIM EnSheng (ensheng@gametize.com)