-
Notifications
You must be signed in to change notification settings - Fork 0
30 lines (27 loc) · 940 Bytes
/
docs.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
name: GitHub Actions Vercel Production Deployment
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
on:
push:
branches:
- main
jobs:
deploy-production:
runs-on: ubuntu-latest
steps:
- name: 🧺 checkout
uses: actions/checkout@v3
- name: 🐱 use .nvmrc
uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
cache: "npm"
- name: 📌 npm install
run: npm ci --prefer-offline --no-audit
- name: 〽️ pull vercel environment information
run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
- name: 🔧 build project artifacts
run: vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
- name: 🐕 deploy project artifacts to vercel
run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }}