Fund vote accounts with 1 lamport only (#4512)

This commit is contained in:
Michael Vines 2019-06-03 14:48:01 -07:00 committed by GitHub
parent 40a4ac15f1
commit 9754e551cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 6 deletions

View File

@ -187,14 +187,11 @@ fn main() -> Result<(), Box<dyn error::Error>> {
let bootstrap_storage_keypair = read_keypair(bootstrap_storage_keypair_file)?;
let mint_keypair = read_keypair(mint_keypair_file)?;
// TODO: de-duplicate the stake once passive staking
// is fully implemented
// https://github.com/solana-labs/solana/issues/4213
let (vote_account, vote_state) = vote_state::create_bootstrap_leader_account(
&bootstrap_vote_keypair.pubkey(),
&bootstrap_leader_keypair.pubkey(),
0,
bootstrap_leader_stake_lamports,
1,
);
let mut genesis_block = GenesisBlock::new(
@ -212,7 +209,7 @@ fn main() -> Result<(), Box<dyn error::Error>> {
),
// where votes go to
(bootstrap_vote_keypair.pubkey(), vote_account),
// passive bootstrap leader stake, duplicates above temporarily
// passive bootstrap leader stake
(
bootstrap_stake_keypair.pubkey(),
stake_state::create_delegate_stake_account(

View File

@ -102,7 +102,7 @@ setup_validator_accounts() {
# Fund the vote account from the node, with the node as the node_pubkey
$solana_wallet --keypair "$node_keypair_path" --url "http://$entrypoint_ip:8899" \
create-vote-account "$vote_pubkey" "$node_pubkey" "$stake" || return $?
create-vote-account "$vote_pubkey" "$node_pubkey" 1 || return $?
# Fund the stake account from the node, with the node as the node_pubkey
$solana_wallet --keypair "$node_keypair_path" --url "http://$entrypoint_ip:8899" \