Generate set of validators keys for IBFT
1.3K
Generate set of validators and observers keys for IBFT:
private key, public key, addressData will be added to existing secrets and ConfigMaps:
| type | name | keys |
|---|---|---|
| secret | account-pwd | account.pwd |
| secret | validators, observers, operator-governance, operator-treasury | *.private_key |
| ConfigMap | validators, observers, operator-governance, operator-treasury | *.pub_key, *.address |
docker build -t ibft-keys-generator .
Run and connect to remote kubernetes cluster using default local kube config
./cm_writer/main.py -k remote -n test --validators 4 --observers 1
Run and connect to kube-apiserver from internal pod (inside kubernetes cluster)
docker run -ti clearmatics/ibft-keys-generator
usage: main.py [-h] [-k {pod,remote}] [-n NAMESPACE] [--validators VALIDATORS]
[--observers OBSERVERS]
Generate set of keys for initialising the network and deploy it to kubernetes
etcd
optional arguments:
-h, --help show this help message and exit
-k {pod,remote} Type of connection to kube-apiserver: pod or remote
(default: pod)
-n NAMESPACE Kubernetes namespace.
--validators VALIDATORS
number of validators. Should be more than 4 for ibft
(default: 4)
--observers OBSERVERS
number of observers minimum 1 (default: 1)
NAMESPACE=test
kubectl -n $NAMESPACE get secrets account-pwd -o 'go-template={{index .data "account.pwd"}}' | base64 --decode; echo ""
Get private key of first observer (id == 0)
NAMESPACE=test
kubectl -n $NAMESPACE get secrets observers -o 'go-template={{index .data "0.private_key"}}' | base64 --decode; echo ""
Get list of addresses for each validator
NAMESPACE=test
kubectl -n $NAMESPACE get configmap validators -o yaml |grep .address
Content type
Image
Digest
Size
76 MB
Last updated
almost 7 years ago
docker pull clearmatics/ibft-keys-generator