Skip to content

History and Pending request page #7

History and Pending request page

History and Pending request page #7

name: Deploy Components to Mainnet
on:
pull_request:
push:
branches: [main]
jobs:
deploy-mainnet:
name: Deploy components to social.near (mainnet)
runs-on: ubuntu-latest
environment: treasury-devdao.near
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install dependencies
run: npm ci
- name: Deploy widgets
run: |
BRANCH="$(git rev-parse --abbrev-ref HEAD)"
echo "on branch $BRANCH"
if [[ "$BRANCH" != "main" ]]; then
echo "Not on main branch, dry run by diff with treasury-devdao.near"
npm run dry-run:treasury
else
npm run deploy:treasury -- '${{ vars.NEAR_SOCIAL_ACCOUNT_ID }}' sign-as '${{ vars.NEAR_SOCIAL_ACCOUNT_ID }}' network-config mainnet sign-with-plaintext-private-key --signer-public-key '${{ vars.NEAR_SOCIAL_ACCOUNT_PUBLIC_KEY }}' --signer-private-key '${{ secrets.NEAR_SOCIAL_ACCOUNT_PRIVATE_KEY }}' send
fi