Skip to content

Commit c0dc8bb

Browse files
authored
Merge pull request #5 from MatrixAI/feature-environments
Environment support for `js-application-cloudflare` workflows
2 parents 663b6ef + 39f026e commit c0dc8bb

4 files changed

Lines changed: 27 additions & 0 deletions

.github/workflows/application-js-cloudflare-feature-closed.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ name: "CI / Application JS Cloudflare Feature Closed"
33
on:
44
workflow_call:
55
inputs:
6+
environment:
7+
description: 'Deployment Environment'
8+
type: environment
9+
required: true
610
appName:
711
type: string
812
required: true
@@ -34,6 +38,7 @@ jobs:
3438
if: startsWith(inputs.featureBranch, 'feature')
3539
permissions:
3640
contents: read
41+
environment: ${{ inputs.environment }}
3742
steps:
3843
- uses: actions/checkout@v4
3944
with:

.github/workflows/application-js-cloudflare-feature.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ name: "CI / Application JS Cloudflare Feature"
33
on:
44
workflow_call:
55
inputs:
6+
environment:
7+
description: 'Deployment Environment'
8+
type: environment
9+
required: true
610
ref:
711
type: string
812
default: master
@@ -26,6 +30,7 @@ jobs:
2630
runs-on: ubuntu-latest
2731
permissions:
2832
contents: read
33+
environment: ${{ inputs.environment }}
2934
steps:
3035
- uses: actions/checkout@v4
3136
with:
@@ -46,6 +51,7 @@ jobs:
4651
permissions:
4752
contents: read
4853
actions: write
54+
environment: ${{ inputs.environment }}
4955
steps:
5056
- name: Checkout Actions
5157
uses: actions/checkout@v4
@@ -85,6 +91,7 @@ jobs:
8591
concurrency:
8692
group: feature-deployment
8793
cancel-in-progress: false
94+
environment: ${{ inputs.environment }}
8895
steps:
8996
- name: Checkout Actions
9097
uses: actions/checkout@v4

.github/workflows/application-js-cloudflare-master.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ name: "CI / Application JS Cloudflare Master"
33
on:
44
workflow_call:
55
inputs:
6+
environment:
7+
description: 'Deployment Environment'
8+
type: environment
9+
required: true
610
ref:
711
type: string
812
default: master
@@ -24,6 +28,7 @@ jobs:
2428
permissions:
2529
contents: read
2630
actions: write
31+
environment: ${{ inputs.environment }}
2732
steps:
2833
- name: Checkout Actions
2934
uses: actions/checkout@v4
@@ -65,6 +70,7 @@ jobs:
6570
cancel-in-progress: false
6671
permissions:
6772
contents: read
73+
environment: ${{ inputs.environment }}
6874
steps:
6975
- name: Checkout Actions
7076
uses: actions/checkout@v4

.github/workflows/application-js-cloudflare-staging.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ name: "CI / Application JS Cloudflare Staging"
33
on:
44
workflow_call:
55
inputs:
6+
environment:
7+
description: 'Deployment Environment'
8+
type: environment
9+
required: true
610
ref:
711
type: string
812
default: master
@@ -33,6 +37,7 @@ jobs:
3337
runs-on: ubuntu-latest
3438
permissions:
3539
contents: read
40+
environment: ${{ inputs.environment }}
3641
steps:
3742
- uses: actions/checkout@v4
3843
with:
@@ -53,6 +58,7 @@ jobs:
5358
permissions:
5459
contents: read
5560
pull-requests: write
61+
environment: ${{ inputs.environment }}
5662
steps:
5763
- uses: actions/checkout@v4
5864
- name: Create Pull Request from Staging to Master
@@ -77,6 +83,7 @@ jobs:
7783
permissions:
7884
contents: read
7985
actions: write
86+
environment: ${{ inputs.environment }}
8087
steps:
8188
- name: Checkout Actions
8289
uses: actions/checkout@v4
@@ -118,6 +125,7 @@ jobs:
118125
cancel-in-progress: false
119126
permissions:
120127
contents: read
128+
environment: ${{ inputs.environment }}
121129
steps:
122130
- name: Checkout Actions
123131
uses: actions/checkout@v4
@@ -160,6 +168,7 @@ jobs:
160168
permissions:
161169
contents: write
162170
pull-requests: write
171+
environment: ${{ inputs.environment }}
163172
steps:
164173
- uses: actions/checkout@v4
165174
with:

0 commit comments

Comments
 (0)