-
Notifications
You must be signed in to change notification settings - Fork 45
75 lines (64 loc) · 1.72 KB
/
master.yaml
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
---
name: Master branch workflow
on:
push:
branches:
- master
paths-ignore:
- "**.md"
pull_request:
branches:
- master
paths-ignore:
- "**.md"
env:
GALAXY_ROLE_NAME: christiangda.amazon_cloudwatch_agent
defaults:
run:
working-directory: "christiangda.amazon_cloudwatch_agent"
jobs:
test:
name: "Python ${{ matrix.python }} - Ansible ${{ matrix.ansible }} - OS ${{ matrix.scenario }}"
runs-on: ubuntu-latest
strategy:
matrix:
python: [3.9]
ansible: [">=4.1"]
scenario: ["redhat-8-docker"]
steps:
- name: Check out the codebase.
uses: actions/checkout@v3
with:
path: ${{ env.GALAXY_ROLE_NAME }}
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v4
with:
python: ${{ matrix.python }}
- name: Upgrade pip
run: |
python -m pip install --upgrade pip
- name: Install ansible ${{ matrix.ansible }} and dependencies
env:
ANSIBLE_VERSION: ${{ matrix.ansible }}
run: |
pip install ansible"$ANSIBLE_VERSION"
pip install molecule
pip install docker
pip install 'molecule[docker]'
pip install flake8
pip install selinux
pip install docker
pip install pylint
pip install rope
pip install ansible-lint
- name: Show versions
run: |
flake8 --version
molecule --version
ansible --version
python -VV
- name: Run molecule on ${{ matrix.scenario }}
env:
SCENARIO: ${{ matrix.scenario }}
run: |
molecule test --scenario-name $SCENARIO