1.0.7 • Published 2 years ago
redstone-pusher v1.0.7
examples
!NOTE The example uses the testnet cluster and program at
2tcbDvTs2LkKKx9xwizMHRBKxKgtWBihRnZoDnbxtc8k
Requirements
- Keypair generation and airdrop:
- node and npm, used 20.15.0 and 10.7.0
solanaCLI ^1.18.17 Solanajqfor parsing JSON
Usage
You need to create a keypair
solana-keygen new -o example-keypair.jsonGrab some SOL from the faucet
solana airdrop 1 --url testnet --keypair example-keypair.jsonFor mainnet use, the keypair has to hold some real SOL, pushing a single feed ID with 3 signers costs like 0.000005 SOL
To run for multiple feeds, start a separate process for each, max 1 feed ID per process
Then,
npm install && npm run buildPush Data
- Testnet
npm run start -- \
--private-key ./example-keypair.json \
--network testnet \
--feed-id AVAX # or BTC, ETH, etc., any feed from redstone avax prod service- Mainnet
npm run start -- \
--private-key $HOME/.config/solana/id.json \
--network mainnet-beta \
--feed-id AVAX # or BTC, ETH, etc., any feed from redstone avax prod serviceCheck Price
- Testnet
npm run start -- \
--check-price AVAX \
--network testnet- Mainnet
npm run start -- \
--check-price AVAX \
--network mainnet