Skip to content

Commit 90d9507

Browse files
committed
chore: Github Action을 이용한 수동 vercel 배포
1 parent 9d879e3 commit 90d9507

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/build.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Build and Vercel Preview Deployment on Main
2+
3+
env:
4+
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
5+
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
6+
VERCEL_ENV: preview
7+
8+
on:
9+
push:
10+
branches:
11+
- main
12+
- chore/tag-cd
13+
14+
jobs:
15+
Deploy-Production:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v3
19+
20+
- name: Install Vercel CLI
21+
run: npm install --global vercel@latest
22+
23+
- name: Pull Vercel Environment Information
24+
run: vercel pull --yes --environment=${{ env.VERCEL_ENV }} --token=${{ secrets.VERCEL_TOKEN }}
25+
26+
- name: Build Project Artifacts
27+
run: vercel build --yes --target=${{ env.VERCEL_ENV }} --token=${{ secrets.VERCEL_TOKEN }}
28+
29+
- name: Deploy Project Artifacts to Vercel
30+
run: vercel deploy --prebuilt --target=${{ env.VERCEL_ENV }} --token=${{ secrets.VERCEL_TOKEN }}

0 commit comments

Comments
 (0)