Files
vmn-ansible/.gitea/workflows/deploy_new_config.yaml
T
max 5215f8d082
Deploy new config to the Ansible server / trigger-webhook (pull_request) Successful in 24s
CHANGE: adds new webhooks to the gitea action
2026-08-18 13:36:29 +04:00

28 lines
816 B
YAML

name: Deploy new config to the Ansible server
run-name: Config is being deployed
on:
pull_request:
types: [closed]
branches: [ main ]
env:
REGISTRY: git.vmn.su
OWNER: max
REPO: vmn-ansible
jobs:
trigger-webhook:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: Trigger the webhook to start pulling the latest version from the repo
# LAN IP is used because those hosts are in the same network
run: curl "http://192.168.0.38:9000/hooks/pull-latest"
- name: Trigger the webhook to update python and ansible modules
run: curl "http://192.168.0.38:9000/hooks/run-update-script"
- name: Trigger the webhook to run the playbook
run: curl "http://192.168.0.38:9000/hooks/run-maintain-playbook"