Support win #30
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
lint: | |
name: Ansible Lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # needed for progressive mode to work | |
- name: Run ansible-lint | |
uses: ansible/ansible-lint-action@v6 | |
molecule: | |
name: Molecule | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
distro: | |
- rockylinux9 | |
- ubuntu2404 | |
- ubuntu2204 | |
- ubuntu2004 | |
- debian12 | |
- debian11 | |
steps: | |
- name: Check out the codebase. | |
uses: actions/checkout@v4 | |
- name: Set up Python 3. | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
- name: Install test dependencies. | |
run: pip3 install ansible molecule molecule-plugins[docker] docker | |
- name: Run Molecule tests. | |
run: molecule test | |
env: | |
MOLECULE_DISTRO: ${{ matrix.distro }} | |
molecule-mac: | |
name: ${{ matrix.os }}-${{ matrix.arch }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- macos-13 | |
- macos-14 | |
include: | |
- os: macos-13 | |
arch: intel | |
- os: macos-14 | |
arch: arm | |
steps: | |
- name: Check out the codebase. | |
uses: actions/checkout@v4 | |
- name: Set up Python 3. | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
- name: Install test dependencies. | |
run: pip3 install ansible molecule | |
- name: Run Molecule tests. | |
run: molecule test -s macos | |
molecule-win: | |
name: molecule-win | |
runs-on: windows-latest | |
steps: | |
- name: Check out the codebase. | |
uses: actions/checkout@v4 | |
- uses: devops37/ssh-win-from-wsl@v1 | |
- name: Install Python3 on wsl | |
shell: wsl-bash {0} | |
run: | | |
sudo apt-get update | |
sudo apt-get -y install python3 python3-pip | |
python3 -m pip install ansible molecule | |
- name: Run Molecule tests. | |
shell: wsl-bash {0} | |
run: | | |
ip route show | grep -i default | awk '{ print $3}' | |
pwd | |
ip a | |
molecule test -s windows |