Deploy blocks subgraph in sushiswap-subgraph stack
This commit is contained in:
parent
8c67429861
commit
2c7c8301ed
@ -12,12 +12,13 @@ services:
|
|||||||
- APP=v3
|
- APP=v3
|
||||||
# - NETWORK=lotus-fixturenet
|
# - NETWORK=lotus-fixturenet
|
||||||
- NETWORK=filecoin
|
- NETWORK=filecoin
|
||||||
command: ["bash", "-c", "./run-v3.sh"]
|
command: ["bash", "-c", "./v3/run-v3.sh && ./blocks/run-blocks.sh"]
|
||||||
working_dir: /app/subgraphs/v3
|
working_dir: /app/subgraphs
|
||||||
volumes:
|
volumes:
|
||||||
- ../config/sushiswap-subgraph-v3/filecoin.js:/app/config/filecoin.js
|
- ../config/sushiswap-subgraph-v3/filecoin.js:/app/config/filecoin.js
|
||||||
# - ../config/sushiswap-subgraph-v3/lotus-fixturenet.js.template:/app/config/lotus-fixturenet.js.template
|
# - ../config/sushiswap-subgraph-v3/lotus-fixturenet.js.template:/app/config/lotus-fixturenet.js.template
|
||||||
- ../config/sushiswap-subgraph-v3/run-v3.sh:/app/subgraphs/v3/run-v3.sh
|
- ../config/sushiswap-subgraph-v3/run-v3.sh:/app/subgraphs/v3/run-v3.sh
|
||||||
|
- ../config/sushiswap-subgraph-v3/run-blocks.sh:/app/subgraphs/blocks/run-blocks.sh
|
||||||
# - sushiswap_core_deployment:/app/subgraphs/v3/core-deployments/docker
|
# - sushiswap_core_deployment:/app/subgraphs/v3/core-deployments/docker
|
||||||
# - sushiswap_periphery_deployment:/app/subgraphs/v3/deployments/docker
|
# - sushiswap_periphery_deployment:/app/subgraphs/v3/deployments/docker
|
||||||
extra_hosts:
|
extra_hosts:
|
||||||
|
@ -20,5 +20,10 @@ module.exports = {
|
|||||||
],
|
],
|
||||||
// TODO: Check value
|
// TODO: Check value
|
||||||
minimumEthLocked: 1.5
|
minimumEthLocked: 1.5
|
||||||
}
|
},
|
||||||
|
blocks: {
|
||||||
|
// https://github.com/sushiswap/subgraphs/blob/master/config/filecoin.js
|
||||||
|
address: '0x719e14fcb364bb05649bd525eb6c4a2d0d4ea2b7',
|
||||||
|
startBlock: 2867000,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
15
app/data/config/sushiswap-subgraph-v3/run-blocks.sh
Executable file
15
app/data/config/sushiswap-subgraph-v3/run-blocks.sh
Executable file
@ -0,0 +1,15 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
echo "Building blocks subgraph and deploying to graph-node..."
|
||||||
|
|
||||||
|
cd blocks
|
||||||
|
|
||||||
|
pnpm run generate
|
||||||
|
pnpm run build
|
||||||
|
|
||||||
|
pnpm exec graph create --node http://graph-node:8020/ sushiswap/blocks
|
||||||
|
pnpm exec graph deploy --node http://graph-node:8020/ --ipfs http://ipfs:5001 --version-label 0.1.0 sushiswap/blocks
|
||||||
|
|
||||||
|
echo "Done"
|
@ -29,7 +29,10 @@ set -e
|
|||||||
# Write the replaced content back to the JavaScript file
|
# Write the replaced content back to the JavaScript file
|
||||||
# echo "$replaced_content" > /app/config/lotus-fixturenet.js
|
# echo "$replaced_content" > /app/config/lotus-fixturenet.js
|
||||||
|
|
||||||
echo "Building subgraph and deploying to graph-node..."
|
echo "Building v3 subgraph and deploying to graph-node..."
|
||||||
|
|
||||||
|
cd v3
|
||||||
|
|
||||||
pnpm run generate
|
pnpm run generate
|
||||||
pnpm run build
|
pnpm run build
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user