Production Tag Deployment #28
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: CI | |
# on: | |
# push: | |
# branches: ["main"] | |
# pull_request: | |
# types: [opened, synchronize] | |
# jobs: | |
# build: | |
# name: Build and Test | |
# timeout-minutes: 15 | |
# runs-on: ubuntu-latest | |
# # To use Remote Caching, uncomment the next lines and follow the steps below. | |
# # env: | |
# # TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | |
# # TURBO_TEAM: ${{ vars.TURBO_TEAM }} | |
# steps: | |
# - name: Check out code | |
# uses: actions/checkout@v4 | |
# with: | |
# fetch-depth: 2 | |
# - uses: pnpm/action-setup@v3 | |
# with: | |
# version: 8 | |
# - name: Setup Node.js environment | |
# uses: actions/setup-node@v4 | |
# with: | |
# node-version: 20 | |
# cache: 'pnpm' | |
# - name: Install dependencies | |
# run: pnpm install | |
# - name: Build | |
# run: pnpm build | |
# - name: Test | |
# run: pnpm test | |
name: Production Tag Deployment | |
env: | |
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | |
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} | |
on: | |
push: | |
# Pattern matched against refs/tags | |
tags: | |
- '*' # Push events to every tag not containing / | |
jobs: | |
Deploy-Production: | |
environment: Production | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '18' | |
- name: Install pnpm | |
run: npm install -g pnpm@6 | |
- name: Install Vercel CLI | |
run: npm install --global vercel@latest | |
- name: Pull Vercel Environment Information | |
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }} | |
- name: Build Project Artifacts | |
run: vercel build --target preview --token=${{ secrets.VERCEL_TOKEN }} | |
- name: Deploy Project Artifacts to Vercel | |
run: vercel deploy --prebuilt --target preview --token=${{ secrets.VERCEL_TOKEN }} |