The versions are the ones that work for me locally.
- Rust
- Solana CLI tools (
v1.14.20
) - Anchor CLI (
v0.27.0
) - Node(
v16.19.1
) - wasm-pack(
v0.12.1
)
From the root directory :
npm install
npx lerna run build --scope=@pythnetwork/staking
cd staking
npm run localnet
This command spawns a validator at http://localhost:8899
with the staking program deployed in the genesis block at the address :
pytS9TjG1qyAZypk7n8rw8gfW9sUaqqYyMhJQ4E7JCQ
Additionally it will :
- Initialize and configure the staking program
- Create the Pyth token at the address in
staking/app/keypairs/pyth_mint.json
- Airdrop SOL to two hypothetical users Alice and Bob (their keys are in
staking/app/keypairs/
) - Airdrop Pyth tokens to Alice and Bob
- Create some stake accounts for Alice and Bob and deposit some tokens
Once that's done, keep the process running. Open a new terminal, change directory to frontend/
and run:
npm run dev