-
Notifications
You must be signed in to change notification settings - Fork 1
30 lines (25 loc) · 821 Bytes
/
deploy.yml
File metadata and controls
30 lines (25 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: Deploy to Production
on:
push:
branches:
- main
jobs:
trigger-deployment:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Trigger deployment
run: |
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ secrets.DEPLOY_PAT }}" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/${{ github.repository_owner }}/hp-ansible/dispatches \
-d '{"event_type":"deploy"}'
- name: Deployment triggered
run: |
echo "✅ Deployment workflow triggered successfully"
echo "Repository: ${{ github.repository_owner }}/hp-ansible"
echo "Event type: deploy"