This repository has been archived by the owner on Jan 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (60 loc) · 1.6 KB
/
molecule.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
---
name: Molecule Test
on:
pull_request:
push:
branches:
- main
defaults:
run:
working-directory: "mirsg.ssl_certificates"
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Check out the codebase
uses: actions/checkout@v4
with:
path: "mirsg.ssl_certificates"
- name: Set up Python 3
uses: actions/setup-python@v4
with:
python-version: "3.x"
- name: Install lint dependencies
run: pip3 install yamllint
- name: Lint code
run: |
yamllint .
molecule:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
molecule_docker_image:
- geerlingguy/docker-rockylinux8-ansible:latest
- geerlingguy/docker-centos7-ansible:latest
molecule_docker_command:
- /usr/sbin/init
steps:
- name: Check out the codebase
uses: actions/checkout@v4
with:
path: "mirsg.ssl_certificates"
- name: Set up Python 3.9
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install test dependencies
run: |
sudo apt-get update && sudo apt-get -y install rsync
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt
- name: Test with molecule
run: |
molecule test
env:
PY_COLORS: "1"
ANSIBLE_FORCE_COLOR: "1"
MOLECULE_DOCKER_IMAGE: ${{ matrix.molecule_docker_image }}
MOLECULE_DOCKER_COMMAND: ${{ matrix.molecule_docker_command }}