No description
Find a file
2017-06-06 18:18:27 +03:00
docker inital 2017-05-25 12:13:59 +03:00
docs@8d8b69d824 inital 2017-05-25 12:13:59 +03:00
libraries Change default seed node 2017-06-06 18:18:27 +03:00
programs Update max core supply in genesis, properly track total supply for vesting balances in bts accounts and other changes 2017-06-06 11:17:04 +03:00
tests Update max core supply in genesis, properly track total supply for vesting balances in bts accounts and other changes 2017-06-06 11:17:04 +03:00
.gitignore inital 2017-05-25 12:13:59 +03:00
.gitmodules inital 2017-05-25 12:13:59 +03:00
CMakeLists.txt inital 2017-05-25 12:13:59 +03:00
Dockerfile inital 2017-05-25 12:13:59 +03:00
Doxyfile inital 2017-05-25 12:13:59 +03:00
gui_version inital 2017-05-25 12:13:59 +03:00
HEADER inital 2017-05-25 12:13:59 +03:00
LICENSE.md inital 2017-05-25 12:13:59 +03:00
README.md Update chain id 2017-06-02 13:04:08 +03:00
testnet-shared-accounts.txt inital 2017-05-25 12:13:59 +03:00
testnet-shared-balances.txt inital 2017-05-25 12:13:59 +03:00
testnet-shared-committee-members.txt inital 2017-05-25 12:13:59 +03:00
testnet-shared-private-keys.txt inital 2017-05-25 12:13:59 +03:00
testnet-shared-vesting-balances.txt inital 2017-05-25 12:13:59 +03:00
testnet-shared-witnesses.txt inital 2017-05-25 12:13:59 +03:00
Vagrantfile inital 2017-05-25 12:13:59 +03:00

Intro for new developers and witnesses

This is a quick introduction to get new developers and witnesses up to speed on Peerplays blockchain. It is intended for witnesses plannig to join a live, already deployed blockchain.

Starting A Peerplays Node

For Ubuntu 14.04 LTS and up users, see this link first: https://github.com/cryptonomex/graphene/wiki/build-ubuntu

and then proceed with:

git clone https://github.com/pbsa/peerplays.git
cd peerplays
git submodule update --init --recursive
cmake -DCMAKE_BUILD_TYPE=Release .
make
./programs/witness_node/witness_node

Launching the witness creates required directories. Next, stop the witness and continue.

vi witness_node_data_dir/config.ini
p2p-endpoint = 0.0.0.0:9777
rpc-endpoint = 127.0.0.1:8090
seed-node = 213.184.225.234:59500

Start the witness back up

./programs/witness_node/witness_node

Then, in a separate terminal window, start the command-line wallet cli_wallet:

./programs/cli_wallet/cli_wallet

To set your initial password to 'password' use:

>>> set_password password
>>> unlock password

A list of CLI wallet commands is available here.

Testnet

  • chain-id - 5b37954aa0d33a8e0d57b084995c262a7c13dbc0693d3e96654e63ff45a9ceec

Register your username at the faucet address

https://595-dev.pixelplex.by/

Use the get_private_key_from_password command

You will to generate owner and active keys

get_private_key_from_password the_key_you_received_from_the_faucet your_witness_username active
get_private_key_from_password the_key_you_received_from_the_faucet your_witness_username owner

This will reveal an array for each ['PPYxxx', 'xxxx']

import_keys into your cli_wallet

  • use the second value in each array returned from the previous step for the private key
  • be sure to wrap your username in quotes
  • import all 2 keys received above
import_key "your_witness_username" xxxx
import_key "your_witness_username" xxxx

Upgrade your account to lifetime membership

upgrade_account your_witness_username true

Create your witness (substitute the url for your witness information)

  • place quotes around url
create_witness your_witness_username "url" true

Be sure to take note of the block_signing_key

IMPORTANT (issue below command using block_signing_key just obtained)

get_private_key block_signing_key

Compare this result to

dump_private_keys

You should see 3 pairs of keys. The last pair should match your block_signing_key and this is the one you will use in the next step!

Get your witness id

get_witness username (note the "id" for your config)

Modify your witness_node config.ini to include your witness id and private key pair.

Comment out the existing private-key before adding yours

vim witness_node_data_dir/config.ini

witness-id = "1.6.x"
private-keys = ['block_signing_key','private_key_for_your_block_signing_key']

start your witness back up

./programs/witness_node/witness_node

If it fails to start, try with these flags (not for permanent use)

./programs/witness_node/witness_node --resync --replay

Vote for yourself

vote_for_witness your_witness_account your_witness_account true true

Ask to be voted in!

Join @Peerplays Telegram group to find information about the witness group. http://t.me/@peerplayswitness

You will get logs that look like this:

2070264ms th_a       application.cpp:506           handle_block         ] Got block: #87913 time: 2017-05-27T16:34:30 latency: 264 ms from: bhuz-witness  irreversible: 87903 (-10)
2071000ms th_a       witness.cpp:204               block_production_loo ] Not producing block because slot has not yet arrived
2072000ms th_a       witness.cpp:204               block_production_loo ] Not producing block because slot has not yet arrived
2073000ms th_a       witness.cpp:201               block_production_loo ] Not producing block because it isn't my turn

Assuming you've received votes, you will start producing as a witness at the next maintenance interval (once per hour). You can check your votes with.

get_witness your_witness_account

Running specific tests

  • tests/chain_tests -t block_tests/name_of_test