Pay for queries from watcher to indexer mode Ponder apps in payments stack #573

Merged
nikugogoi merged 8 commits from sk-split-ponder-container into main 2023-10-12 08:46:44 +00:00
3 changed files with 7 additions and 7 deletions
Showing only changes of commit 1d6544aacb - Show all commits

View File

@ -22,7 +22,7 @@ services:
- ../config/ponder/ponder.indexer.config.ts:/app/examples/token-erc20/ponder.config.ts
- peers_ids:/peers
- nitro_deployment:/nitro
- ponder_nitro_data:/app/examples/token-erc20/.ponder/nitro-db
- ponder_indexer_nitro_data:/app/examples/token-erc20/.ponder/nitro-db
ports:
- "42070"
extra_hosts:
@ -42,6 +42,7 @@ services:
CERC_PONDER_NITRO_CHAIN_URL: ${CERC_PONDER_NITRO_CHAIN_URL:-http://fixturenet-eth-geth-1:8546}
CERC_RELAY_MULTIADDR: ${CERC_RELAY_MULTIADDR}
CERC_INDEXER_GQL_ENDPOINT: ${CERC_INDEXER_GQL_ENDPOINT:-http://ponder-app-indexer:42070/graphql}
CERC_INDEXER_NITRO_ADDRESS: ${CERC_INDEXER_NITRO_ADDRESS:-0x67D5b55604d1aF90074FcB69b8C51838FFF84f8d}
CERC_INDEXER_NITRO_PAY_AMOUNT: ${CERC_INDEXER_NITRO_PAY_AMOUNT:-50}
command: ["bash", "./ponder-start.sh"]
volumes:
@ -49,7 +50,7 @@ services:
- ../config/ponder/ponder.watcher.config.ts:/app/examples/token-erc20/ponder.config.ts
- peers_ids:/peers
- nitro_deployment:/nitro
- ponder_nitro_data:/app/examples/token-erc20/.ponder/nitro-db
- ponder_watcher_nitro_data:/app/examples/token-erc20/.ponder/nitro-db
ports:
- "42069"
extra_hosts:
@ -58,4 +59,5 @@ services:
volumes:
peers_ids:
nitro_deployment:
ponder_nitro_data:
ponder_indexer_nitro_data:
ponder_watcher_nitro_data:

View File

@ -54,6 +54,7 @@ echo "UPSTREAM_NITRO_ADDRESS=\"$CERC_UPSTREAM_NITRO_ADDRESS\"" >> "$env_file"
echo "UPSTREAM_NITRO_MULTIADDR=\"$CERC_UPSTREAM_NITRO_MULTIADDR\"" >> "$env_file"
echo "UPSTREAM_NITRO_PAY_AMOUNT=\"$CERC_UPSTREAM_NITRO_PAY_AMOUNT\"" >> "$env_file"
echo "INDEXER_GQL_ENDPOINT=\"$CERC_INDEXER_GQL_ENDPOINT\"" >> "$env_file"
echo "INDEXER_NITRO_ADDRESS=\"$CERC_INDEXER_NITRO_ADDRESS\"" >> "$env_file"
echo "INDEXER_NITRO_PAY_AMOUNT=\"$CERC_INDEXER_NITRO_PAY_AMOUNT\"" >> "$env_file"
cat "$env_file"

View File

@ -42,8 +42,5 @@ export const config: Config = {
contractAddresses,
relayMultiAddr: process.env.RELAY_MULTIADDR!,
store: "./.ponder/nitro-db",
},
options: {
indexerGqlEndpoint: process.env.INDEXER_GQL_ENDPOINT,
},
}
};