Skip to content

fix: DomainRegistry (#127) #90

fix: DomainRegistry (#127)

fix: DomainRegistry (#127) #90

name: build & test & deploy contracts on amoy network
on:
push:
branches:
- master
paths:
- '**.sol'
env:
CHAIN_ID: "80002"
FOUNDRY_PROFILE: "ci"
jobs:
deploy-amoy:
runs-on: ubuntu-latest
env:
PVK_A1: ${{ secrets.amoy_deployer_pk }}
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/setup-node@v3
with:
node-version: 16.14
- name: build node modules
run: yarn install --non-interactive
- name: lint contracts
run: yarn prettier:check
- name: install foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly
- name: build contracts
run: forge build
- name: test contracts
run: forge test
- name: deploy contracts to amoy
run: forge script ./script/DeployAll.s.sol --rpc-url ${{ secrets.amoy_rpc_url }}
--etherscan-api-key ${{ secrets.polygonscan_api_key }}
--private-key $PVK_A1
--verify
--broadcast
- name: commit deployments.txt
run: |
git config --global user.name 'CI'
git config --global user.email '[email protected]'
git add deployments.txt
git commit -am "update deployments.txt"
git push