forked from juju4/ansible-sumocollector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
84 lines (78 loc) · 2.34 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
---
dist: xenial
sudo: required
rvm:
- 2.6
env:
- distribution: centos
version: 7
suite: default
- distribution: ubuntu
version: 18.04
suite: default
- distribution: ubuntu
version: 16.04
suite: default
# - distribution: alpine
# version: 3.4
- distribution: debian
version: 9
suite: default
- distribution: debian
version: 8
suite: default
- distribution: centos
version: 7
suite: default-runas
- distribution: ubuntu
version: 18.04
suite: default-runas
- distribution: ubuntu
version: 16.04
suite: default-runas
- distribution: debian
version: 8
suite: default-runas
## failing in kitchen/docker, ok kitchen/vagrant: ernestas-poskus.docker : Ensure docker service is enabled
# - distribution: centos
# version: 7
# suite: default-docker
- distribution: ubuntu
version: 18.04
suite: default-docker
- distribution: ubuntu
version: 16.04
suite: default-docker
- distribution: debian
version: 8
suite: default-docker
before_install:
- env
- pwd
- find -ls
## use appropriate role path and not github name
- "[ -f get-dependencies.sh ] && sh -x get-dependencies.sh"
- sudo pip install ansible
## need to use chef gem for some reason? BAD PATH https://github.com/chef/chef-dk/issues/15
# - chef gem install kitchen
- gem install kitchen
- gem install kitchen-ansible
- gem install kitchen-sync
- gem install kitchen-docker
- gem list
- which kitchen
- KITCHEN_YAML=.kitchen.docker.yml kitchen diagnose --all
script:
## avoid locale issue under xenial docker, https://github.com/pypa/pip/issues/3575
- export LC_ALL=C.UTF-8
- export LANG=C.UTF-8
- KITCHEN_YAML=.kitchen.docker.yml kitchen verify ${suite}-${distribution}-${version//./}
after_failure:
- KITCHEN_YAML=.kitchen.docker.yml kitchen exec ${suite}-${distribution}-${version//./} -c 'systemctl -l --no-pager status'
- KITCHEN_YAML=.kitchen.docker.yml kitchen exec ${suite}-${distribution}-${version//./} -c 'journalctl -xe --no-pager'
after_script:
- KITCHEN_YAML=.kitchen.docker.yml kitchen exec ${suite}-${distribution}-${version//./} -c 'cat /opt/SumoCollector/logs/collector.log'
# Clean up
- KITCHEN_YAML=.kitchen.docker.yml kitchen destroy default-${distribution}-${version//./}
notifications:
webhooks: https://galaxy.ansible.com/api/v1/notifications/