Add a CI workflow to deploy frontend #35

Merged
prathamesh merged 5 commits from deep-stack/snowballtools-base:ag-frontend-ci into main 2024-11-06 09:20:02 +00:00
Showing only changes of commit 9946784b98 - Show all commits

View File

@ -0,0 +1,49 @@
name: Deploy Snowball frontend
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
steps:
- name: Check out repository
uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Download yarn
run: |
curl -fsSL -o /usr/local/bin/yarn https://github.com/yarnpkg/yarn/releases/download/v1.22.21/yarn-1.22.21.js
chmod +x /usr/local/bin/yarn
- name: Set up environment
run: |
# Create a config file with necessary endpoints and placeholders for secrets
cat > packages/deployer/config.yml <<EOF
services:
registry:
rpcEndpoint: https://laconicd-sapo.laconic.com
gqlEndpoint: https://laconicd-sapo.laconic.com/api
userKey: ${{ secrets.REGISTRY_USER_KEY }}
bondId: ${{ secrets.REGISTRY_BOND_ID }}
chainId: laconic-testnet-2
gasPrice: 0.001alnt
EOF
- name: Run Deploy Script
env:
REGISTRY_BOND_ID: ${{ secrets.REGISTRY_BOND_ID }}
DEPLOYER_LRN: ${{ secrets.DEPLOYER_LRN }}
AUTHORITY: ${{ secrets.AUTHORITY }}
run: |
packages/deployer/deploy-frontend.sh