Skip to content
This repository has been archived by the owner on Mar 23, 2024. It is now read-only.

Deploy to Vercel

Deploy to Vercel #9

Workflow file for this run

name: Deploy to Vercel
on:
workflow_dispatch:
workflow_run:
workflows: [frontend CI, Server CI]
types: [completed]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: List contents of client_artifact directory
run: ls -la
- name: List contents of server_artifact directory
run: ls -la
- name: Download client artifact
uses: actions/download-artifact@v2
with:
name: client-success-artifact
path: client_artifact
continue-on-error: true
- name: Download server artifact
uses: actions/download-artifact@v2
with:
name: server-success-artifact
path: server_artifact
continue-on-error: true
- name: Check artifacts
run: |
if [ ! -f client_artifact/client_success.txt ] || [ ! -f server_artifact/server_success.txt ]; then
echo "One or both workflows did not succeed. Skipping deployment."
exit 1
fi
- name: Deploy to Vercel
uses: amondnet/vercel-action@v19
with:
vercel-token: ${{ secrets.VERCEL_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}