A OLSF devnet runs with the following nodes. If you have permissions connect with shh root@ip-address
alice = 161.35.13.169
bob = 167.71.84.248
carol = 104.131.56.224
# eve is not in genesis set, but has configs to join
eve = 157.230.15.42
- (optional) Participants: Set-up the list of genesis participants
- Infra: create devnet mock infrastucture (github repositories)
- Install: Host setup for OS and binaries
- End-to-end: Do a full devnet start:
make devnet
- Quick: Do a quick smoke test with fixture genesis.blob:
make smoke
- Onboard: Onboard a new validator (eve):
make devnet-join
Access to nodes is controlled by this github administrators.
Upon logging in, administrators should check the saved terminal sessions with tmux a
.
This assumes there is a github repo which is dedicated to devnet. These instruction assume the layout of the genesis set is found in: github.com/OLSF/dev-genesis
.
The defaults use personas in the genesis set are: alice
, bob
, carol
whose configs and mnemonics can be found in /fixtures/
Optionally change the set layout with:
- Create a new set layout with the accounts of nodes participating in devnet, file:
util/set_layout_devnet.toml
- On any of the nodes run
make set-layout
(just run once).
These repos are necessary for accurate mocking of main net.
- OLSF/dev-genesis: the mock repo for genesis registrations.
- OLSF/dev-epoch-archive: the mock repo for epoch archives.
This only needs to be done once per session, or time the devnet configs change: Move standard library, set_layout, IP addresses.
-
On one machine (
alice
) pull both of those repos. -
Do a genesis "registration" for each of the nodes alice, bob, carol.
make dev-register
- From /libra/ source:
make dev-infra
1. OS dependencies can be installed with libra/util/setup.sh
. Devnet nodes usually are already configured, run this only if adding new nodes.
For each node, set the NS (namespace) for that persona, e.g.:
export NODE_ENV=test NS=alice TEST=y
for prod
, stage
or test
.
> export NODE_ENV=test
will use "easy" difficulty of vdf and stdlib testnet settings.
> export NODE_ENV=stage
will use "hard" difficulty of vdf and stdlib stagingnet settings which is similar to prod, except accelerated epochs.
> export NODE_ENV=prod
will use "hard" difficulty of vdf and the production stdlib (epochs take 24hrs, and account creation is rate limited).
3. Set the name of the persona on each machine, with the NS (namespace) env variable.
> export NS=alice
- Set if this is a test network
> export TEST=y
- This is a shortcut for quick
smoke
testing of the devnet. You can set the nodes to do a genesis from a previously created genesis.blob which was stored to/fixtures/
. Themake smoke
command will default toV=current
.
These "versions" need to be in ./fixtures/genesis/
they are a shortcut for configuring a devnet. Certain versions for the alice, bob, carol configurations are stored to /fixtures/genesis.
>export V=v2.4.6
use make check
and inspect if the env variables are correct.
Note: if some fields are missing make fixtures
can copy files to correct locations. Only needed for debugging as this command is already run with smoke-reg
below.
These instructions assumes three nodes in ceremony (Alice, Bob, Carol), plus one which will be onboarded (Eve). As per the "layout" file.
Preferably run these commands in a screen
or tmux
, such as screen -S node
, and connect with screen -rd node
If something is wrong with the genesis ceremony repository (github.com/OLSF/dev-genesis) then the ceremony needs to be rerun (instead of using the fixtures).
- (OPTIONAL) This instruciton is in the INFRA section above. But if standard library changes for genesis, need to reregister, alice, bob, carol to the mock genesis repo. Do this on all hosts.
make dev-register
- Run ceremony on all nodes, and start:
make devnet
- Start each node from genesis fixtures
# use './fixtures/genesis/current' for genesis blob and waypoint
make frozen
# use './fixtures/genesis/<version>' for fixtures
V=<version> make frozen
Using the mnemonic from /fixtures/memonic/eve.mnem
:
NOTE: remember to pull same code above.
make dev-join
NOTE: backups of devnet should be created for this version number at this repo: github.com/OLSF/dev-epoch-archive Do as the typical onboarding procedure.
- pull same number as above, and build with
make bins
onboard keygen
to make new keysol onboard --next -t
to start each step of the onboarding process.
NOTE: the validator-wizard will be pulling data from dev-epoch-archive
To start the tower app, you'll need to exit screen
, and start a new one. (ctrl+a then ctrl+d to exit without disconnecting screen)
- Start a new screen with
screen -S tower
or reconnect to existing withscreen -rd tower
- execute the tower app
cargo run -p tower -- start
- Enter the mnemonic for the persona of that node. Can be found for example in
/fixtures/mnemonic/alice.mnem