Skip to content

Vercel Production Deployment #13

Vercel Production Deployment

Vercel Production Deployment #13

Workflow file for this run

name: Vercel Production Deployment
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
push:
branches:
- main
jobs:
Deploy-Production:
if: github.repository_owner == 'Dada878'
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
runs-on: ubuntu-latest
steps:
- run: echo ::set-env name=GHA_OWNER::$(echo $GITHUB_REPOSITORY | awk -F / '{print $1}')
shell: bash
- uses: actions/checkout@v4
- name: Set timezone to Asia/Taipei
uses: szenius/[email protected]
with:
timezoneLinux: "Asia/Taipei"
timezoneMacos: "Asia/Taipei"
- name: Generate Schedule Json
uses: CCIP-App/schedule-json-generator-action@v2
with:
gcp-api-key: ${{ secrets.GCP_API_KEY }}
spreadsheet-key: "1AAxHzhqVpmMkUVncgysKPVf6f7lVyvKQMGJZqNJb6aw"
default-avatar: "https://sitcon.org/2022/imgs/deafult_avatar.jpg"
avatar-base-url: "https://sitcon.org/2025/avatar/"
output-path: ./public/sessions.json
- name: Install Vercel CLI
run: npm install --global vercel@latest
- 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 }}