forked from streamingfast/substreams-eth-block-meta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
37 lines (29 loc) · 1.02 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
ENDPOINT ?= eth.firehose.pinax.network:9000
STOP_BLOCK ?= +10
.PHONY: build
build:
cargo build --target wasm32-unknown-unknown --release
.PHONY: stream_db
stream_db: build
substreams run -e $(ENDPOINT) substreams.yaml db_out -t $(STOP_BLOCK)
.PHONY: stream_graph
stream_graph: build
substreams run -e $(ENDPOINT) substreams.yaml graph_out -t $(STOP_BLOCK)
.PHONY: stream_kv
stream_kv: build
substreams run -e $(ENDPOINT) substreams.yaml kv_out -t $(STOP_BLOCK)
.PHONY: codegen
codegen:
substreams protogen ./substreams.yaml --exclude-paths="sf/substreams,google"
.PHONE: package
package: build
substreams pack -o substreams.spkg substreams.yaml
.PHONE: deploy_local
deploy_local: package
graph codegen
graph build --ipfs http://localhost:5001 subgraph.yaml
graph create block_meta --node http://127.0.0.1:8020
graph deploy --node http://127.0.0.1:8020 --ipfs http://127.0.0.1:5001 --version-label v0.0.1 block_meta subgraph.yaml
.PHONE: undeploy_local
undeploy_local:
graphman --config "$(GRAPH_CONFIG)" drop --force block_meta