File tree 1 file changed +12
-5
lines changed
1 file changed +12
-5
lines changed Original file line number Diff line number Diff line change 7
7
# Allows you to run this workflow manually from the Actions tab
8
8
workflow_dispatch :
9
9
10
- # Triggers the workflow on pull request events
11
- pull_request :
12
- branches :
13
- - master
10
+ # Uncomment these lines to trigger the workflow on pull request events
11
+ # pull_request:
12
+ # branches:
13
+ # - master
14
+
15
+ # deploy on comment "/deploy-review-app"
16
+ issue_comment :
17
+ types : [created, edited]
14
18
15
19
# Convert the GitHub secret variables to environment variables for use by the Control Plane CLI
16
20
env :
17
21
CPLN_ORG : ${{secrets.CPLN_ORG_STAGING}}
18
22
CPLN_TOKEN : ${{secrets.CPLN_TOKEN_STAGING}}
19
- PR_NUMBER : ${{github.event.number}}
23
+ # Uncomment this line to use the PR number from the pull requests trigger event (that trigger is commented)
24
+ # PR_NUMBER: ${{ github.event.pull_request.number || github.event.issue.number }}
25
+ PR_NUMBER : ${{ github.event.issue.number }}
20
26
21
27
jobs :
22
28
deploy-to-control-plane-review :
29
+ if : ${{ github.event_name != 'issue_comment' || (github.event.comment.body == '/deploy-review-app' && github.event.issue.pull_request) }}
23
30
runs-on : ubuntu-latest
24
31
25
32
steps :
You can’t perform that action at this time.
0 commit comments