File tree Expand file tree Collapse file tree 2 files changed +38
-1
lines changed Expand file tree Collapse file tree 2 files changed +38
-1
lines changed Original file line number Diff line number Diff line change
1
+ name : CI/CD Workflow
2
+
3
+ on :
4
+ push :
5
+ release :
6
+ types :
7
+ - published
8
+
9
+ jobs :
10
+ test :
11
+ runs-on : ubuntu-latest
12
+ steps :
13
+ - name : Checkout repository
14
+ uses : actions/checkout@v2
15
+
16
+ - name : Run tests
17
+ run : |
18
+ echo "TODO: Replace this with actual tests"
19
+
20
+ deploy-to-staging :
21
+ needs : test
22
+ if : github.ref_name == 'main'
23
+ concurrency : staging
24
+ uses : " ./.github/workflows/deploy.yml"
25
+ with :
26
+ environment : staging
27
+ secrets : inherit
28
+
29
+ deploy-to-production :
30
+ needs : test
31
+ if : github.ref_name == 'production'
32
+ concurrency : production
33
+ uses : " ./.github/workflows/deploy.yml"
34
+ with :
35
+ environment : production
36
+ secrets : inherit
Original file line number Diff line number Diff line change 1
1
# A reusable workflow that deploys the contents of a repository to a target environment.
2
+ # https://docs.github.com/en/actions/using-workflows/reusing-workflows#creating-a-reusable-workflow
2
3
3
- name : Deploy
4
+ name : Deployment Workflow
4
5
5
6
permissions :
6
7
id-token : write
You can’t perform that action at this time.
0 commit comments