-
Notifications
You must be signed in to change notification settings - Fork 15
31 lines (31 loc) · 1.05 KB
/
vercelPullRequest.yml
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
31
name: Create vercel preview URL on pull request
on:
pull_request_target:
branches:
- new
jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: trstringer/manual-approval@v1
timeout-minutes: 240
with:
secret: ${{ github.TOKEN }}
approvers: thedevyashsaini # GitHub username of the approver
minimum-approvals: 1
issue-title: "Deploying PR to dev from staging"
issue-body: "Please approve or deny the deployment of this PR."
exclude-workflow-initiator-as-approver: true
additional-approved-words: ''
additional-denied-words: ''
- uses: actions/checkout@v4
- uses: amondnet/vercel-action@v25
id: vercel-deploy
with:
vercel-token: ${{ secrets.VERCEL_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
vercel-org-id: ${{ secrets.ORG_ID}}
vercel-project-id: ${{ secrets.PROJECT_ID}}
- name: preview-url
run: |
echo ${{ steps.vercel-deploy.outputs.preview-url }}