From 8a5a693c1ab1039d9ac2541061b6c763f278648e Mon Sep 17 00:00:00 2001 From: Jayant Krishnamurthy Date: Wed, 11 Jan 2023 08:25:14 -0800 Subject: [PATCH 1/2] document the filters --- third_party/pyth/price-service/.env.sample | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/third_party/pyth/price-service/.env.sample b/third_party/pyth/price-service/.env.sample index b7526873ad..85ece24da3 100644 --- a/third_party/pyth/price-service/.env.sample +++ b/third_party/pyth/price-service/.env.sample @@ -1,7 +1,17 @@ # Local DevNet: SPY_SERVICE_HOST=0.0.0.0:7072 -## Filters (if provided) should be valid JSON like below: +# Filters (if provided) should be valid JSON like below: +# These filters tell the spy to only retrieve messages sent from certain chains/contracts. +# Pyth price updates can come from the following emitters: +# +# testnet +# {"chain_id": 1, "emitter_address": "f346195ac02f37d60d4db8ffa6ef74cb1be3550047543a4a9ee9acf4d78697b0"} # solana devnet +# {"chain_id": 26, "emitter_address": "a27839d641b07743c0cb5f68c51f8cd31d2c0762bec00dc6fcd25433ef1ab5b6"} # pythtest (pythnet devnet) +# +# mainnet +# {"chain_id": 1, "emitter_address": "6bb14509a612f01fbbc4cffeebd4bbfb492a86df717ebe92eb6df432a3f00a25"} # solana mainnet +# {"chain_id": 26, "emitter_address": "f8cd23c2ab91237730770bbea08d61005cdda0984348f3f6eecb559638c0bba0"} # pythnet SPY_SERVICE_FILTERS=[{"chain_id":1,"emitter_address":"71f8dcb863d176e2c420ad6610cf687359612b6fb392e0642b0ca6b1f186aa3b"}] # Number of seconds to sync with spy to be sure to have latest messages From 12957b1fc9441060173bb94b9962f5c208a517c2 Mon Sep 17 00:00:00 2001 From: Jayant Krishnamurthy Date: Wed, 11 Jan 2023 08:35:49 -0800 Subject: [PATCH 2/2] better doc --- third_party/pyth/price-service/.env.sample | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/third_party/pyth/price-service/.env.sample b/third_party/pyth/price-service/.env.sample index 85ece24da3..beaee791b3 100644 --- a/third_party/pyth/price-service/.env.sample +++ b/third_party/pyth/price-service/.env.sample @@ -3,15 +3,8 @@ SPY_SERVICE_HOST=0.0.0.0:7072 # Filters (if provided) should be valid JSON like below: # These filters tell the spy to only retrieve messages sent from certain chains/contracts. -# Pyth price updates can come from the following emitters: -# -# testnet -# {"chain_id": 1, "emitter_address": "f346195ac02f37d60d4db8ffa6ef74cb1be3550047543a4a9ee9acf4d78697b0"} # solana devnet -# {"chain_id": 26, "emitter_address": "a27839d641b07743c0cb5f68c51f8cd31d2c0762bec00dc6fcd25433ef1ab5b6"} # pythtest (pythnet devnet) -# -# mainnet -# {"chain_id": 1, "emitter_address": "6bb14509a612f01fbbc4cffeebd4bbfb492a86df717ebe92eb6df432a3f00a25"} # solana mainnet -# {"chain_id": 26, "emitter_address": "f8cd23c2ab91237730770bbea08d61005cdda0984348f3f6eecb559638c0bba0"} # pythnet +# See the docker-compose..yaml files in the price-service directory for the appropriate +# configuration for a testnet/mainnet pyth price-service deployment. SPY_SERVICE_FILTERS=[{"chain_id":1,"emitter_address":"71f8dcb863d176e2c420ad6610cf687359612b6fb392e0642b0ca6b1f186aa3b"}] # Number of seconds to sync with spy to be sure to have latest messages