forked from pyslackers/ansible-role-haproxy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
26 lines (25 loc) · 858 Bytes
/
.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
---
language: python
python: "3.6"
sudo: required
matrix:
fast_finish: true
before_install:
# Install Updates
- sudo apt-get update -qq
- sudo apt-get install -qq python-apt
install:
- pip install ansible ansible-lint
- pip --version
- python --version
- ansible --version
- "printf '[defaults]\nroles_path = ../' > ansible.cfg"
script:
- ansible-lint tasks/main.yml
- ansible-playbook -i tests/inventory --syntax-check --list-tasks tests/test.yml
- ansible-playbook -i tests/inventory --connection=local --become -vvvv tests/test.yml -u root --skip-tags travis-exempt
- >
ansible-playbook -i tests/inventory --connection=local --become -vvvv tests/test.yml -u root --skip-tags travis-exempt
| grep -q 'changed=0.*failed=0'
&& (echo 'Idempotence test: pass' && exit 0)
|| (echo 'Idempotence test: fail' && exit 1)