System Tests for the cxf-spring-boot-starter including a reverse proxy and the Spring Boot project using the starter both inside Docker Containers.
This test project will run a terraform script on AWS to create the needed infrastructure. The Servers are tagged by this script to mark the specific roles. The provisioning of the servers will be handled by ansible. Here we use the approach of a dynamic inventory script that will retrieve the state using the aws api. This script is using boto.
I recommend installing boto and boto3 in a python virtualenv so you don't need to worry abount your current python installation.
virtualenv ~/.virtualenvs/boto
pip install boto
pip install boto3
pip install docker-py
You need to make sure that the python virtualenv is activated. In order to use amazon web services you need to provide the specific access keys If you are using IAM you may want to check if your access key ist active: https://console.aws.amazon.com/iam/home?region=eu-west-1#/users/dev?section=security_credentials
source ~/.virtualenvs/boto/bin/activate
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
Ansible seems to have issues regarding the virtualenv. Using Python virtualenv with ansible addresses this issue for a static inventory. Since I'm using a ec2 dynaimic inventory I can't use this fix...
Current error message
failed: [52.214.200.37] (item=1) => {"failed": true, "item": "1", "msg": "Failed to import docker-py - No module named docker. Try `pip install docker-py`"}