This repository has been archived by the owner on Jul 3, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
67 lines (57 loc) · 2.47 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
---
os: linux
dist: bionic
language: shell
env:
jobs:
- MOLECULE_SCENARIO_NAME="ubuntu-20.04"
- MOLECULE_SCENARIO_NAME="ubuntu-19.10"
- MOLECULE_SCENARIO_NAME="ubuntu-18.04"
- MOLECULE_SCENARIO_NAME="centos-8"
- MOLECULE_SCENARIO_NAME="centos-7"
- MOLECULE_SCENARIO_NAME="suse-15"
- MOLECULE_SCENARIO_NAME="debian-10"
- MOLECULE_SCENARIO_NAME="fedora-32"
jobs:
allow_failures:
- env: MOLECULE_SCENARIO_NAME="ubuntu-19.10"
- env: MOLECULE_SCENARIO_NAME="centos-8"
- env: MOLECULE_SCENARIO_NAME="centos-7"
- env: MOLECULE_SCENARIO_NAME="suse-15"
- env: MOLECULE_SCENARIO_NAME="debian-10"
- env: MOLECULE_SCENARIO_NAME="fedora-32"
before_install:
- |
curl -Os https://releases.hashicorp.com/vagrant/2.2.9/vagrant_2.2.9_x86_64.deb
curl -Os https://releases.hashicorp.com/vagrant/2.2.9/vagrant_2.2.9_SHA256SUMS
curl -Os https://releases.hashicorp.com/vagrant/2.2.9/vagrant_2.2.9_SHA256SUMS.sig
gpg --receive-key 51852D87348FFC4C
gpg --verify vagrant_2.2.9_SHA256SUMS.sig vagrant_2.2.9_SHA256SUMS
sha256sum -c vagrant_2.2.9_SHA256SUMS 2>&1 | grep OK
sudo apt-get update && sudo apt-get install -y bridge-utils dnsmasq-base ebtables libvirt-bin libvirt-dev qemu-kvm qemu-utils ruby-dev
sudo dpkg -i vagrant_2.2.9_x86_64.deb
sudo vagrant plugin install vagrant-libvirt
rm -rf vagrant_2.2.9_*
- |
sudo apt-get -y purge python3-openssl && sudo apt-get -y autoremove
sudo apt-get update && sudo apt-get install -y ca-certificates curl gcc iproute2 pwgen python3 python3-dev sudo
curl -skL https://bootstrap.pypa.io/get-pip.py | sudo -H python3
sudo -H pip3 install --upgrade --ignore-installed --requirement requirements.txt
install:
- |
export ROLE=$(echo $TRAVIS_REPO_SLUG | sed 's/^.*\/ansible-role-/\//g')
mkdir -p $HOME/.ansible/roles
mkdir -p $HOME/.ansible/collections/alvistack
ln -s $TRAVIS_BUILD_DIR $HOME/.ansible/roles/$ROLE
molecule dependency
script:
- |
source ./scripts/run-tests.sh \
&& sudo -E molecule lint -s $MOLECULE_SCENARIO_NAME \
&& sudo -E molecule syntax -s $MOLECULE_SCENARIO_NAME \
&& sudo -E molecule converge -s $MOLECULE_SCENARIO_NAME \
&& travis_wait 120 sudo -E molecule idempotence -s $MOLECULE_SCENARIO_NAME \
&& sudo -E molecule side-effect -s $MOLECULE_SCENARIO_NAME \
&& sudo -E molecule verify -s $MOLECULE_SCENARIO_NAME
notifications:
webhooks: https://galaxy.ansible.com/api/v1/notifications/?branch=master