Skip to content

6.0.2

6.0.2 #57

Workflow file for this run

name: Deploy to Vercel
on:
push:
tags:
- 'mainnet-*'
- 'testnet-*'
jobs:
deploy-mainnet:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/mainnet-')
steps:
- uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- name: Install dependencies
run: npm install
- name: Install Vercel CLI
run: npm install -g vercel
- name: Pull Vercel project settings (Production)
run: vercel pull --scope=aresrpg --yes --environment=production --token ${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
- name: Build Vite project
run: npm run build
- name: Build Vercel output (Production)
run: vercel build --prod
- name: Deploy to Vercel (Production)
run: |
url=$(vercel deploy --scope=aresrpg --prebuilt --prod --token ${{ secrets.VERCEL_TOKEN }})
echo $url
vercel alias set $url app.aresrpg.world --scope=aresrpg --token ${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
deploy-testnet:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/testnet-')
steps:
- uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- name: Install dependencies
run: npm install
- name: Install Vercel CLI
run: npm install -g vercel
- name: Pull Vercel project settings (Preview)
run: vercel pull --scope=aresrpg --yes --environment=preview --token ${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
- name: Build Vite project
run: npm run build
- name: Build Vercel output (Preview)
run: vercel build
- name: Deploy to Vercel (Testnet)
run: |
url=$(vercel deploy --scope=aresrpg --prebuilt --token ${{ secrets.VERCEL_TOKEN }})
echo $url
vercel alias set $url testnet.aresrpg.world --scope=aresrpg --token ${{ secrets.VERCEL_TOKEN }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}