Refresh Registry #12980
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: Refresh Registry | |
on: | |
push: | |
branches: | |
- master | |
schedule: | |
- cron: "0 8 * * *" | |
workflow_dispatch: {} | |
jobs: | |
refresh: | |
runs-on: ubuntu-latest | |
name: Refresh Registry from chain | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT | |
- name: Yarn Cache | |
uses: actions/cache@v3 | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-modules- | |
- run: yarn install | |
- run: mkdir -p data/ | |
- run: cp -R static/* data/ | |
- run: yarn compile-rewarders-list | |
- run: yarn build | |
- run: yarn fetch-all-rewarders | |
env: | |
NETWORK: mainnet-beta | |
MAINNET_SOLANA_RPC_ENDPOINT: ${{ secrets.MAINNET_SOLANA_RPC_ENDPOINT }} | |
# - run: yarn fetch-all-rewarders | |
# env: | |
# NETWORK: devnet | |
- run: yarn decorate-rewarders | |
- run: yarn build-token-list | |
env: | |
NETWORK: mainnet-beta | |
MAINNET_SOLANA_RPC_ENDPOINT: ${{ secrets.MAINNET_SOLANA_RPC_ENDPOINT }} | |
# - run: yarn build-token-list | |
# env: | |
# NETWORK: devnet | |
- run: yarn build-tvl-list | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
deploy_key: ${{ secrets.REWARDER_LIST_BUILD_DEPLOY_KEY }} | |
external_repository: QuarryProtocol/rewarder-list-build | |
publish_branch: master | |
publish_dir: ./data/ |