Skip to content

TEMP: Use 'devel' action version #18

TEMP: Use 'devel' action version

TEMP: Use 'devel' action version #18

---
name: Test collection roles
on:
- push
- pull_request
jobs:
check_roles:
name: Verify modified roles
runs-on: ubuntu-latest
outputs:
ipaserver: ${{ steps.mod_files.outputs.ipaserver }}
ipareplica: ${{ steps.mod_files.outputs.ipareplica }}
ipaclient: ${{ steps.mod_files.outputs.ipaclient }}
steps:
- uses: actions/[email protected]
with:
fetch-depth: 1
- name: Check modified roles
id: mod_files
shell: bash
run: |
set -eu
git remote add upstream https://github.com/freeipa/ansible-freeipa
git fetch --depth 1 upstream master
git diff -M --name-only upstream/master \
| grep "^roles" \
| cut -d/ -f2 \
| sort | uniq \
| sed "s/\(.*\)/\1=true/"
git diff -M --name-only upstream/master \
| grep "^roles" \
| cut -d/ -f2 \
| sort | uniq \
| sed "s/\(.*\)/\1=true/" >> $GITHUB_OUTPUT
debug:
name: Debug
needs: [check_roles]
runs-on: ubuntu-latest
steps:
- name: Check vars
run: |
echo ${{ needs.check_roles.outputs.ipaserver }}
echo ${{ needs.check_roles.outputs.ipareplica }}
echo ${{ needs.check_roles.outputs.ipaclient }}
test_ipaserver:
name: Test ipaserver role
needs: [check_roles]
if: ${{ needs.check_roles.outputs.ipaserver }}
runs-on: ubuntu-latest
strategy:
matrix:
cluster_config:
- ipaserver_ca.yml
# - ipaserver_ca_dns_kra_ad.yml
# - ipaserver_ipaclient_ca.yml
steps:
- uses: actions/[email protected]
with:
fetch-depth: 1
- name: Test ipaserver
uses: rjeffman/FreeIPA-Cluster-Test@devel
with:
cluster_configuration: tests/deployment/${{ matrix.cluster_config }}
test_playbooks: >-
tests/user/test_user.yml
tests/group/test_group.yml
tests/host/test_host.yml
tests/hbacrule/test_hbacrule.yml
# test_ipareplica:
# name: Test ipareplica role
# needs: [check_roles]
# if: ${{ needs.check_roles.outputs.ipareplica }}
# runs-on: ubuntu-latest
# strategy:
# matrix:
# # The ipaserver configuration is always "ca-dns-kra-ad"
# cluster_config:
# - ipareplica_none.yml
# - ipareplica_ca.yml
# steps:
#
# test_ipaclientt:
# name: Test ipareplica role
# needs: [check_roles]
# if: ${{ needs.check_roles.outputs.ipareplica }}
# runs-on: ubuntu-latest
# strategy:
# matrix:
# # The ipaserver configuration is always "ca-dns-kra-ad"
# cluster_config:
# - ipareplica_none.yml
# - ipareplica_ca.yml
# - ipareplica_copy.yml
# steps: