21 lines
432 B
YAML
21 lines
432 B
YAML
name: Run Ansible Playbook
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
run-ansible:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Copy base64 encoded SSH key to file
|
|
run: |
|
|
echo "${{ secrets.ANSIBLE_SSH_KEY }}" | base64 --decode > ansible_key
|
|
chmod 600 ansible_key
|
|
- name: cat ansible_key
|
|
run: cat ansible_key |