Update stage1 instructions to generate genesis from subscribers CSV
This commit is contained in:
parent
59a1562c7f
commit
eb272a307c
@ -2,6 +2,10 @@
|
|||||||
|
|
||||||
Once all the participants have completed their onboarding, stage0 laconicd chain can be halted and stage1 chain can be initialized and started
|
Once all the participants have completed their onboarding, stage0 laconicd chain can be halted and stage1 chain can be initialized and started
|
||||||
|
|
||||||
|
## Prerequisite
|
||||||
|
|
||||||
|
* A CSV having the subscribers (`subscribers.csv`) placed at `/srv/laconicd/csvs`
|
||||||
|
|
||||||
## Login
|
## Login
|
||||||
|
|
||||||
* Log in as `dev` user on the deployments VM
|
* Log in as `dev` user on the deployments VM
|
||||||
@ -12,6 +16,29 @@ Once all the participants have completed their onboarding, stage0 laconicd chain
|
|||||||
cd /srv
|
cd /srv
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Map subscribers to participants
|
||||||
|
|
||||||
|
* Fetch updated scripts in testnet-laconicd-stack:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
laconic-so fetch-stack git.vdb.to/cerc-io/testnet-laconicd-stack --pull
|
||||||
|
```
|
||||||
|
|
||||||
|
* Create a CSV with subscribers who have onboarded as participants:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Change to scripts dir
|
||||||
|
cd ~/cerc/testnet-laconicd-stack/scripts
|
||||||
|
|
||||||
|
# Install dependencies and build
|
||||||
|
yarn && yarn build
|
||||||
|
|
||||||
|
# Run script
|
||||||
|
yarn map-subscribers-to-participants --subscribers-csv /srv/laconicd/csvs/subscribers.csv --output /srv/laconicd/csvs/subscribed-participants.csv
|
||||||
|
|
||||||
|
# This should create the CSV file at /srv/laconicd/csvs/subscribed-participants.csv
|
||||||
|
```
|
||||||
|
|
||||||
## Halt stage0
|
## Halt stage0
|
||||||
|
|
||||||
* Confirm the the currently running node is for stage0 chain:
|
* Confirm the the currently running node is for stage0 chain:
|
||||||
@ -36,6 +63,12 @@ Once all the participants have completed their onboarding, stage0 laconicd chain
|
|||||||
|
|
||||||
## Start stage1
|
## Start stage1
|
||||||
|
|
||||||
|
* Fetch updated scripts in fixturenet-laconicd-stack:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
laconic-so fetch-stack git.vdb.to/cerc-io/fixturenet-laconicd-stack --pull
|
||||||
|
```
|
||||||
|
|
||||||
* Rebuild laconicd container with `>=v0.1.7` to enable `slashing` module:
|
* Rebuild laconicd container with `>=v0.1.7` to enable `slashing` module:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@ -54,13 +87,7 @@ Once all the participants have completed their onboarding, stage0 laconicd chain
|
|||||||
laconic-so --stack ~/cerc/fixturenet-laconicd-stack/stack-orchestrator/stacks/fixturenet-laconicd build-containers --force-rebuild
|
laconic-so --stack ~/cerc/fixturenet-laconicd-stack/stack-orchestrator/stacks/fixturenet-laconicd build-containers --force-rebuild
|
||||||
```
|
```
|
||||||
|
|
||||||
* Fetch updated scripts in fixturenet-laconicd-stack:
|
* Use the scripts in fixturenet-laconicd-stack to generate genesis file for stage1 using CSV with subscribed participants with token allocations:
|
||||||
|
|
||||||
```bash
|
|
||||||
laconic-so fetch-stack git.vdb.to/cerc-io/fixturenet-laconicd-stack --pull
|
|
||||||
```
|
|
||||||
|
|
||||||
* Use the scripts in fixturenet-laconicd-stack to generate genesis file for stage1 using onboarding participants from stage0 chain with token allocations:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd /srv/laconicd
|
cd /srv/laconicd
|
||||||
@ -73,7 +100,8 @@ Once all the participants have completed their onboarding, stage0 laconicd chain
|
|||||||
# Generate the genesis file
|
# Generate the genesis file
|
||||||
# Participant allocation: 1000000000000 (10^12)
|
# Participant allocation: 1000000000000 (10^12)
|
||||||
# Validator allocation: 2000000000000000 (10^15)
|
# Validator allocation: 2000000000000000 (10^15)
|
||||||
./scripts/generate-stage1-genesis-using-allocations.sh $DEPLOYMENTS_DIR/stage0-deployment 1000000000000 2000000000000000
|
# These amounts is used only if funding amount is not present in the input CSV
|
||||||
|
./scripts/generate-stage1-genesis-from-csv.sh /srv/laconicd/csvs/subscribed-participants.csv 1000000000000 2000000000000000
|
||||||
|
|
||||||
# If you see the error "Error: genesis.json file already exists: /root/.laconicd/config/genesis.json",
|
# If you see the error "Error: genesis.json file already exists: /root/.laconicd/config/genesis.json",
|
||||||
# remove the temporary data directory and try again
|
# remove the temporary data directory and try again
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# cli
|
# scripts
|
||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user