The role used .yaml while the molecule scenario used .yml, because molecule hard codes molecule.yml and has no fallback for the other extension. Aligning all files on .yml keeps the extension consistent across the repository and avoids surprises when a tool only supports one of both spellings. Co-authored-by: Copilot <copilot@github.com>
31 lines
811 B
YAML
31 lines
811 B
YAML
name: Molecule
|
|
|
|
on:
|
|
pull_request:
|
|
types: [ "opened", "reopened", "synchronize" ]
|
|
push:
|
|
branches: [ '**' ]
|
|
tags-ignore: [ '**' ]
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
molecule:
|
|
name: Molecule
|
|
runs-on: ubuntu-latest-amd64
|
|
steps:
|
|
# The scenario includes the role by its name, so the directory must be named like the role and not like the
|
|
# repository. Its parent is used as roles path.
|
|
- uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
|
|
with:
|
|
path: certificate_authority
|
|
- name: Install molecule
|
|
run: |
|
|
apt update --yes
|
|
apt install --yes python3-pip
|
|
pip3 install --break-system-packages molecule docker
|
|
- name: Run molecule
|
|
run: molecule test
|
|
working-directory: certificate_authority
|