Merge pull request #32 from KB-iGOT/Haritest-patch-2 #30
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
# Github workflow for execute ansible playbook | |
name: Dev Env User Update | |
on: | |
workflow_dispatch: | |
push: | |
branches: [main] | |
paths: users/*.yml | |
jobs: | |
checkout: | |
runs-on: kb-dev-jumphost-p1 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
update: | |
strategy: | |
matrix: | |
users: | |
- dev.yml | |
- qa.yml | |
- sa.yml | |
- super-admins.yml | |
- noc.yml | |
- devops.yml | |
- engg.yml | |
runs-on: kb-dev-jumphost-p1 | |
needs: checkout | |
steps: | |
- name: Execute Ansible Playbook | |
uses: dawidd6/action-ansible-playbook@v2.8.0 | |
with: | |
playbook: users.yml | |
directory: ${{ github.workspace }}/ansible | |
options: | | |
--extra-vars "@${{ github.workspace }}/users/${{ matrix.users }}" | |
--inventory-file "${{ github.workspace }}/hosts/dev" |