-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (60 loc) · 1.7 KB
/
ci.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
name: CI
on:
pull_request:
branches: ["*"]
paths-ignore:
- "**.md"
- "LICENSE"
workflow_dispatch:
concurrency:
group: ${{ github.workflow}}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
format:
uses: trfore/ansible-role/.github/workflows/format.yml@main # remote repo
lint_ansible:
needs:
- format
uses: trfore/ansible-role/.github/workflows/lint_ansible.yml@main # remote repo
lint_python:
needs:
- format
uses: trfore/ansible-role/.github/workflows/lint_py.yml@main # remote repo
test:
needs:
- format
- lint_ansible
- lint_python
strategy:
fail-fast: false
matrix:
distro: [centos8, debian10, ubuntu2004]
experimental: [false]
molecule_scenario: ["-s default"]
include:
- distro: ubuntu2004
experimental: true
molecule_scenario: "-s SCENARIO_NAME"
# uses: ./.github/workflows/test_ansible.yml # local, delete if using remote
uses: trfore/ansible-role/.github/workflows/test_ansible.yml@main # remote repo
with:
distro: ${{ matrix.distro }}
experimental: ${{ matrix.experimental }}
molecule_scenario: ${{ matrix.molecule_scenario }}
requirements_file: "requirements/dev-requirements.txt"
check:
if: ${{ always() }}
needs:
- format
- lint_ansible
- lint_python
- test
runs-on: ubuntu-latest
steps:
- run: >-
python -c "assert set([
'${{ needs.format.result }}',
'${{ needs.lint_ansible.result }}',
'${{ needs.lint_python.result }}',
'${{ needs.test.result }}',
]) == {'success'}"