language: python
python:
  - 2.7

sudo: required
dist: trusty

env:
  - ANSIBLE_VERSION=2.2.0.0
  - ANSIBLE_VERSION=2.1.3.0

install:
## Create Docker with Ansible modules and all dependancies
  - docker build --build-arg ver_ansible=$ANSIBLE_VERSION -t juniper/pyez-ansible:travis .
## Install Ansible locally for Ravello and install Roles
  - pip install -q ansible==$ANSIBLE_VERSION
  - cd tests
  - mkdir library
  - git clone https://github.com/Juniper/ravello-ansible.git library/ravello-ansible
  - pip install -r library/ravello-ansible/requirements.txt
  - mv .travis_ansible_python.yaml group_vars/all/travis_ansible_python.yaml

script:
## Start Virtual topology on Ravello with 2 VQFX and collect IP addresses
  - ansible-playbook -i ravello.ini pb.rav.token.create-deploy.yaml
  - ansible-playbook -i ravello.ini pb.rav.token.fqdn_get.yaml

## Execute Tests with Docker
  - docker run -t -i -v $(pwd):/project juniper/pyez-ansible:travis ansible-playbook -i local.ini pb.junos_ping.yaml
  - docker run -t -i -v $(pwd):/project juniper/pyez-ansible:travis ansible-playbook -i local.ini pb.junos_jsnapy.yaml

language: python
python:
  - 2.7

sudo: required
dist: trusty

env:
  - ANSIBLE_VERSION=2.2.0.0
  - ANSIBLE_VERSION=2.1.3.0

install:
## Create Docker with Ansible modules and all dependancies
  - docker build --build-arg ver_ansible=$ANSIBLE_VERSION -t juniper/pyez-ansible:travis .
## Install Ansible locally for Ravello and install Roles
  - pip install -q ansible==$ANSIBLE_VERSION
  - cd tests
  - mkdir library
  - git clone https://github.com/Juniper/ravello-ansible.git library/ravello-ansible
  - pip install -r library/ravello-ansible/requirements.txt
  - mv .travis_ansible_python.yaml group_vars/all/travis_ansible_python.yaml

script:
## Start Virtual topology on Ravello with 2 VQFX and collect IP addresses
  - ansible-playbook -i ravello.ini pb.rav.token.create-deploy.yaml
  - ansible-playbook -i ravello.ini pb.rav.token.fqdn_get.yaml

## Execute Tests with Docker
  - docker run -t -i -v $(pwd):/project juniper/pyez-ansible:travis ansible-playbook -i ravello.ini pb.junos_ping.yaml
  - docker run -t -i -v $(pwd):/project juniper/pyez-ansible:travis ansible-playbook -i ravello.ini pb.junos_jsnapy.yaml

Fix issue with inventory name
Fix issue with inventory name
