Deploy and update final subgraph URLs #37
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub Actions Vercel Preview Deployment | |
env: | |
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | |
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} | |
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }} | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
Deploy-Preview: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Ensure pnpm store directory exists | |
run: mkdir -p ~/.pnpm-store | |
- name: Cache Node Modules and pnpm Store | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.pnpm-store | |
node_modules | |
key: ${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-pnpm- | |
- name: Install pnpm and Vercel CLI | |
run: | | |
npm install -g pnpm vercel@canary | |
- name: Pull Vercel Environment Information | |
run: vercel pull --yes --token=${{ secrets.VERCEL_TOKEN }} | |
- name: Build Project Artifacts | |
run: vercel build --token=${{ secrets.VERCEL_TOKEN }} | |
- name: Deploy Project Artifacts to Vercel | |
run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }} |