Peerplays Launched! Your guide on how to become a witness
peerplays·@someguy123·
0.000 HBDPeerplays Launched! Your guide on how to become a witness
Now that [PeerPlays](https://www.peerplays.com) has launched, many people are still lost on how to set up a witness.
<center></center>
What is PeerPlays?
======
PeerPlays is a decentralized platform for gambling, based on BitShares (the precursor to Steemit). It could have a variety of uses including sports betting, lotteries, dice games, etc.
How do I get a witness?
====
Luckily, I've ported over my popular Steem-in-a-box software, so setting up a witness is a breeze!
My company @privex can even [get you a server paid with STEEM](https://steemit.com/introduceyourself/@privex/we-are-privex-inc-we-accept-steem-protecting-your-privacy-in-the-cloud) for your PeerPlays witness. (@privex actually runs a seed inside the network, meaning you'll sync in 30 seconds flat)
Let's get started.
=========
Since the account faucet isn't online yet, you'll need to ask in the Telegram for an account: https://telegram.me/PeerplaysWitness
Once you have an account, [you'll need to get a Linux server](https://steemit.com/introduceyourself/@privex/we-are-privex-inc-we-accept-steem-protecting-your-privacy-in-the-cloud), I recommend using Ubuntu 16.04. Right now PeerPlays has low requirements, you'll only need a 1-2GB RAM server (but you might want to invest in more RAM for when it gets bigger).
Setting up the server
=====
Now that you have a Linux server online, you'll need to install Docker. This is fast and easy, just 2 commands:
```
sudo apt update && sudo apt install curl git
curl https://get.docker.com | sh
```
If you're using a normal user, make sure to add that user to the docker group, e.g. if your user is called `ubuntu`:
```
sudo usermod -aG docker ubuntu
```
Once you've installed Docker, download my PeerPlays-in-a-box system:
```
git clone https://github.com/Someguy123/peerplays-docker.git
cd peerplays-docker
```
Now, change to the peerplays-docker folder, and let's install and start peerplays (this may take a minute)
```
./run.sh install
./run.sh start
```
For the next part, you'll need to have a PeerPlays account. Since the account faucet isn't online yet, you'll need to ask in the Telegram for an account: https://telegram.me/PeerplaysWitness
Once you have an account, we can continue setting up the witness:
```
./run.sh wallet
```
You should see a prompt like this:
```
new >>>
```
Set a wallet password (this is unrelated to your account password, it's similar to a bitcoin wallet password)
```
set_password "some_secure_password"
unlock "some_secure_password"
```
Now, get your private keys based on your password (if you already have your keys, skip this step)
```
unlocked >>> get_private_key_from_password USERNAME active PASSWORD
[ 'PPYxxx', 'xxxx' ]
unlocked >>> get_private_key_from_password USERNAME owner PASSWORD
[ 'PPYxxx', 'xxxx' ]
```
Import your owner and active key into the wallet
```
unlocked >>> import_key "USERNAME" xxxx
unlocked >>> import_key "USERNAME" xxxx
```
You need to "upgrade your account". You may need to ask someone to send you some PPY tokens on the Telegram before you can do this.
```
unlocked >>> upgrade_account USERNAME true
```
Once you've successfully upgraded, you can now create a witness:
```
create_witness USERNAME "url" true
```
You should see something like this:
```
{
"ref_block_num": 6936,
"ref_block_prefix": 4050013610,
"expiration": "2017-06-06T21:48:12",
"operations": [[
20,{
"fee": {
"amount": 800000,
"asset_id": "1.3.0"
},
"witness_account": "1.2.8892",
"url": "",
"block_signing_key": "PPY5ipyg232HNHTCGR52EZtR6wyCdZPYJoMVmcpfiPRrEyMFUxeJG",
"initial_secret": ""
}
}
```
Make a note of the **block_signing_key**, it's important!
Now, do this following to get your **private block signing key**
```
get_private_key THE_BLOCK_SIGNING_KEY_WHICH_IS_ABOVE
```
You should see a **private key**, beginning with 5. Note this down somewhere with your **public block signing key**.
Now, get your **witness ID**:
```
get_witness USERNAME
```
Make note of the "id" (make sure to not copy the wrong ID)
```
{
.....
"id": "1.6.x"
.....
}
```
Now. Press CTRL-D to exit the wallet.
We'll now update the config for the server:
```
nano data/witness_node_data_dir/config.ini
```
**Comment out** the line starting with p2p-endpoint (i.e. put a # in front of it)
```
#p2p-endpoint = 0.0.0.0:7777
```
Put these shortly after the seed nodes:
```
# the witness ID you got earlier
witness-id = "1.6.x"
# the block keys you were supposed to note down earlier! public and then private
private-keys = ["P...","5..."]
# now save the file! if nano, press CTRL-X and type yes to save
```
Finally, we **restart the server**:
```
./run.sh restart
```
Now hopefully you should have a witness :)
Check the logs to make sure it's working:
```
./run.sh logs
```
You should see something like this:
```
336001ms th_a witness.cpp:201 block_production_loo ] Not producing block because it isn't my turn
336159ms th_a application.cpp:506 handle_block ] Got block: #7273 time: 2017-06-06T22:05:36 latency: 157 ms from: billbutler-witness irreversible: 7260 (-13)
337001ms th_a witness.cpp:204 block_production_loo ] Not producing block because slot has not yet arrived
338001ms th_a witness.cpp:204 block_production_loo ] Not producing block because slot has not yet arrived
```
If you see that, you're probably set up :) - remember you can ask people on the Telegram for help if you're stuck. Join our witness Telegram: https://telegram.me/PeerplaysWitness
----
Do you like what I'm doing for STEEM/Steemit?
---

[Vote for me to be a witness](https://steemit.com/~witnesses) - every vote counts.
---
Don't forget to follow me for more like this.
---
--
Have you ever thought about being a witness yourself? Contact me on STEEMIT.CHAT, I'm happy to guide you! Join in shaping the STEEM economy.
Are you looking for a new server provider? My company @privex offers highly-reliable and affordable dedicated and virtual servers for STEEM, LTC, and BTC! Contact me on STEEMIT.CHAT for more information.👍 someguy123, bloodycritique, leyargoz, condra, daut44, lukestokes, runridefly, bola, albertogm, ipumba, tamersameeh, aggroed, master-set, ardentwolf, privex, ullikume, ausbitbank, scaredycatguide, jfesrom, daynewright, joele, parkermorris, skyefox, applecrisp, krystle, tarazkp, teamsteem, blueorgy, kpine, kouhei-gahaku, lauralemons, steemland.com, steemprentice, hitmeasap, virtualgrowth, lamech-m, steembets, lukinsawyer, evildeathcore, dahaz159, thegame, omarrium, mark-waser, digital-wisdom, ethical-ai, jwaser, bwaser, ellepdub, herpetologyguy, morgan.waser, strong-ai, davidjkelley, technoprogressiv, theprophet0, pheonike, dolov, viktorcapulet, opheliafu, cryptofunk, fleur, bottymcbotface, eem, tinytaruen, hypexals-spiral, thecryptodrive, steemdrive, bravenewcoin, unipsycho, ethansteem, steemsports, webdeals, rebel, donato, andrewawerdna, ap2002, elena000, tradeqwik, steemcenterwiki, bue-witness, bue, mini, healthcare, berlinmoonlight, boy, bunny, daniel.pan, moon, helen.tan, craigslist, bindia, mraldo, rdickey, crawfish37, juvyjabian, arcange, raphaelle, smailer, liondani, erikkartmen, rusteemitblog, detol, dirty.hera, kralizec, worldtraveler, develcuy, marialin, anasya, always1success, bitcoiner, vl248, borishaifa, sharker, burnin, tyler-fletcher, penambang, samether, ratel, raymondspeaks, konti, crypto.owl, bkkshadow, dmilash, gomeravibz, littleboo, romancs, nadin3, xanoxt, tatianka, elena-singer, ekaterinka, htyfn, orenshani7, therajmahal, marel, kostaslou, fbechstein, blockchained, ygern, singa, ribalinux, grandpere, on0tole, sveokla, marinabogumil, cloh76, kell234, hyiparena, zaebars, litrbooh, mama-steem, uuuhha, riosparada, krishtopa, villainblack, leno4ek, victoriart, anton333, steemlift, max-max, gildar, chem1cal, skye1, geoffrey, steemitlotteries, htliao, jesta, drpuffnstuff, teamhumble, nepd, pmartynov, steemychicken1, kingscrown, ihashfury, ostrich, be-like-water, rossco99, boatymcboatface, theshell, writingamigo, soushi888, velimir, fminerten, inv, fmooo, steempty, cryptoemperor, steemradio, yvonnetse, gregory-f, jamie1128, neoxian, prameshtyagi, bluehorseshoe, zeteticmindset, xaero1, kenny-crane, cqf, trafalgar, etcbits, steemitpatina, tuck-fheman, taspingo, ashwim, nicnas, barrydutton, forykw, nenad-ristic, egregorian, lautenglye, syn999, steemspoker, gikitiki, raphaelom, eeks, kwak, brendio, starsteem, betamusic, pharesim, hg6106, bledarus, azazqwe, ajvest, timcliff, lexiconical, thomasgutierrez, ekaterina4ka, fabien, gindor, allyouneedtoknow, kurtbeil, wattacut, pokertravel, felixxx, evimeria, coocoocachoo, budimir, steemvoter, iulianbutanu, dragosroua, raluca, sochul, elevator09, the-ego-is-you, peerplays, mapipaz, eirik, hangeul, cristi, stray, steempower, crypto-p, exavier, mammasitta, emilniz, crackdown, dimarss, datosin, yunus, alaqrab, contentjunkie, klye, aaronmda, jondahl, crshin2me, user786, bsameep, fricibacsi, neroru, joshuaatiemo, bycz, leomichael, ejemai, malicered, furion, koskl, rubenalexander, rondonson, george88, chamviet, shawtyrokdoowop, ginasarasini, globalvanguard, thethreehugs, kide, cocorobert, bobinson, grake, ashvinmaid, lev-abalkin,