-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
44 lines (37 loc) · 1.14 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
---
language: python
python: "2.7"
# Use the new container infrastructure
sudo: required
dist: trusty
services:
- docker
# Install ansible
addons:
apt:
packages:
- python-pip
env:
global:
- PATH="/usr/bin:$PATH"
before_install:
# Ansible doesn't play well with virtualenv
- deactivate
- sudo apt-get update -qq
- sudo apt-get install -y -o Dpkg::Options::="--force-confnew" docker-engine
install:
- sudo pip install docker-py
- sudo apt-get install -y sshpass software-properties-common
- sudo apt-add-repository -y ppa:ansible/ansible
- sudo apt-get update -qq
- sudo apt-get install -y ansible
- sudo rm /usr/bin/python && sudo ln -s /usr/bin/python2.7 /usr/bin/python
- ansible --version
- sudo sed -i '/^#.*host_key_checking /s/^#//' /etc/ansible/ansible.cfg
script:
- sudo ansible-galaxy install -r tests/requirements.yml
- sudo ansible-playbook tests/test.yml -i tests/inventory --syntax-check
- docker stop nginx_host || true
- sudo ansible-playbook tests/test.yml -i tests/inventory
notifications:
webhooks: https://galaxy.ansible.com/api/v1/notifications/