Skip to content

sap_ha_pacemaker_cluster: Stonith SBD enablement, stonith and repos dictionaries #480

sap_ha_pacemaker_cluster: Stonith SBD enablement, stonith and repos dictionaries

sap_ha_pacemaker_cluster: Stonith SBD enablement, stonith and repos dictionaries #480

---
# Worflow for ansible-test sanity tests
name: ansible-test sanity of the collection
on:
pull_request:
branches:
- main
- dev
workflow_dispatch:
jobs:
sanity:
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Set up Python 3
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install test dependencies
run: |
pip3 install ansible ansible-lint==6.8.6
pip3 install ansible-compat==3.0.2
# - name: Install collection dependencies
# run: ansible-galaxy collection install community.general
# - name: List directory /home/runner/work/
# working-directory: /home/runner/
# run: ls -al /home/runner/work/
# - name: List directory /home/runner/work/_actions
# working-directory: /home/runner/
# run: ls -al /home/runner/work/_actions
- name: List directory /home/runner/work/_actions/actions
working-directory: /home/runner/
run: ls -al /home/runner/work/_actions/actions
# - name: List directory /home/runner/work/community.sap_install
# working-directory: /home/runner/
# run: ls -al /home/runner/work/community.sap_install
# - name: List directory /home/runner/work/community.sap_install/community.sap_install
# working-directory: /home/runner/
# run: ls -al /home/runner/work/community.sap_install/community.sap_install
- name: Move the collection to the correct location - Create new directory
run: mkdir -p /home/runner/.ansible/collections/ansible_collections/community
- name: Move the collection to the correct location - Move the collection
working-directory: /home/runner/
run: mv /home/runner/work/community.sap_install/community.sap_install /home/runner/.ansible/collections/ansible_collections/community
# - name: List directory /home/runner/.ansible/collections/ansible_collections/community
# working-directory: /home/runner/
# run: ls -al /home/runner/.ansible/collections/ansible_collections/community
- name: Move the collection to the correct location - Rename the directory
working-directory: /home/runner/
run: mv /home/runner/.ansible/collections/ansible_collections/community/community.sap_install /home/runner/.ansible/collections/ansible_collections/community/sap_install
# - name: List directory /home/runner/.ansible/collections/ansible_collections/community
# working-directory: /home/runner/
# run: ls -al /home/runner/.ansible/collections/ansible_collections/community
# - name: List directory /home/runner/.ansible/collections/ansible_collections/community/sap_install
# working-directory: /home/runner/
# run: ls -al /home/runner/.ansible/collections/ansible_collections/community/sap_install
- name: Run sanity tests
working-directory: /home/runner/.ansible/collections/ansible_collections/community/sap_install
run: ansible-test sanity
- name: Move the collection to its previous location
working-directory: /home/runner/
run: mv /home/runner/.ansible/collections/ansible_collections/community/sap_install /home/runner/work/community.sap_install/community.sap_install