Skip to content

Commit

Permalink
Merge pull request #8 from graphprotocol/juanmardefago/sepolia-config
Browse files Browse the repository at this point in the history
Sepolia/Arbitrum-Sepolia config
  • Loading branch information
juanmardefago authored Nov 28, 2023
2 parents e6e0e04 + dc54da0 commit ea74680
Show file tree
Hide file tree
Showing 9 changed files with 2,280 additions and 16 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/deploy-arbitrum-sepolia-subgraph.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Production Subgraph (Arbitrum-Sepolia)

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2

# Install commands
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '20'
registry-url: https://registry.npmjs.org
- name: yarn add ts-node
run: yarn add ts-node
- name: yarn install
run: yarn
env:
NODE_AUTH_TOKEN: ${{secrets.graphprotocol_npm_token}}

# Run scripts
- name: Prepare addresses testnet
run: ./node_modules/.bin/ts-node ./config/arbitrumSepoliaAddressScript.ts && ./node_modules/.bin/mustache ./config/generatedAddresses.json ./config/addresses.template.ts > ./config/addresses.ts
- name: Prepare testnet
run: ./node_modules/.bin/mustache ./config/generatedAddresses.json subgraph.template.yaml > subgraph.yaml && ./node_modules/@graphprotocol/graph-cli/bin/graph codegen --output-dir src/types/
- name: Deploy to testnet
run: ./node_modules/@graphprotocol/graph-cli/bin/graph deploy graphprotocol/graph-activity-arb-sepolia --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token ${{secrets.access_token}}
35 changes: 35 additions & 0 deletions .github/workflows/deploy-sepolia-subgraph.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Production Subgraph (Sepolia)

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2

# Install commands
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '20'
registry-url: https://registry.npmjs.org
- name: yarn add ts-node
run: yarn add ts-node
- name: yarn install
run: yarn
env:
NODE_AUTH_TOKEN: ${{secrets.graphprotocol_npm_token}}

# Run scripts
- name: Prepare addresses testnet
run: ./node_modules/.bin/ts-node ./config/sepoliaddressScript.ts && ./node_modules/.bin/mustache ./config/generatedAddresses.json ./config/addresses.template.ts > ./config/addresses.ts
- name: Prepare testnet
run: ./node_modules/.bin/mustache ./config/generatedAddresses.json subgraph.template.yaml > subgraph.yaml && ./node_modules/@graphprotocol/graph-cli/bin/graph codegen --output-dir src/types/
- name: Deploy to testnet
run: ./node_modules/@graphprotocol/graph-cli/bin/graph deploy graphprotocol/graph-activity-sepolia --ipfs https://api.thegraph.com/ipfs/ --node https://api.thegraph.com/deploy/ --access-token ${{secrets.access_token}}
Loading

0 comments on commit ea74680

Please sign in to comment.