Skip to content

Commit b7469ca

Browse files
committed
Added deploy to CI.
1 parent c6ef2d3 commit b7469ca

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

.github/workflows/callable-deploy.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Trigger Deployment
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
repo:
7+
type: string
8+
required: true
9+
secrets:
10+
token:
11+
required: true
12+
13+
jobs:
14+
deploy:
15+
name: Trigger Deployment
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- name: Dispatch Deployment
20+
uses: peter-evans/repository-dispatch@v3
21+
with:
22+
token: ${{ secrets.token }}
23+
repository: ${{ inputs.repo }}
24+
event-type: deploy

.github/workflows/on-push-main.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,13 @@ jobs:
2121
image_tag: latest
2222
secrets:
2323
ghcr_token: ${{ secrets.GITHUB_TOKEN }}
24+
25+
deploy:
26+
name: Trigger Deployment
27+
uses: ./.github/workflows/callable-deploy.yml
28+
needs:
29+
- build
30+
with:
31+
repo: ${{ vars.DEPLOYMENT_REPO }}
32+
secrets:
33+
token: ${{ secrets.REPO_DISPATCH_TOKEN }}

0 commit comments

Comments
 (0)