Handle re-running tmkms playbook
This commit is contained in:
parent
6bca4b0e34
commit
eb4ec58893
@ -55,6 +55,9 @@
|
||||
|
||||
# Set desired key name
|
||||
key_name: "laconic-validator"
|
||||
|
||||
# Enable TMKMS
|
||||
tmkms_enabled: true
|
||||
```
|
||||
|
||||
- Export the data directory and mainnet deployment directory as environment variables:
|
||||
@ -248,6 +251,16 @@
|
||||
|
||||
- Note the pubkey logged at start for comparing later with validator pubkey on chain
|
||||
|
||||
- Remove the `priv_validator_key.json` file from TMKMS machine as it is no longer required:
|
||||
|
||||
```bash
|
||||
rm -rf <path-to-priv_validator_key.json>
|
||||
```
|
||||
|
||||
### Start node
|
||||
|
||||
- Run the following steps in the machine where the mainnet node is setup (machine 2)
|
||||
|
||||
- Remove the validator key from node deployment as it is no longer required:
|
||||
|
||||
```bash
|
||||
@ -256,17 +269,6 @@
|
||||
|
||||
NOTE: Store it safely offline in case of an emergency
|
||||
|
||||
### Start node
|
||||
|
||||
- Run the following steps in the machine where the mainnet node is setup (machine 2)
|
||||
|
||||
- Enable TMKMS in the laconicd node configuration:
|
||||
|
||||
```bash
|
||||
# Set TMKMS_ENABLED to true in the node's config.env
|
||||
echo "TMKMS_ENABLED=true" >> $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR/config.env
|
||||
```
|
||||
|
||||
- Copy the genesis file to the mainnet deployment tmp directory:
|
||||
|
||||
```bash
|
||||
@ -323,6 +325,46 @@
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR exec laconicd "laconicd query bank balances $EARLY_SUPPORTS_ACC_ADDR"
|
||||
```
|
||||
|
||||
## Update config
|
||||
|
||||
- Run following steps to update the config for TMKMS and node
|
||||
|
||||
### TMKMS
|
||||
|
||||
- Run these steps in the machine where the TMKMS service is setup (machine 4)
|
||||
|
||||
- Stop the TMKMS deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$TMKMS_DEPLOYMENT_DIR stop
|
||||
```
|
||||
|
||||
- Update `~/cerc/laconicd-stack/playbooks/tmkms/tmkms-vars.yml` with required values
|
||||
|
||||
- Run ansible playbook to run the TMKMS:
|
||||
|
||||
```bash
|
||||
ansible-playbook -i localhost, -c local ~/cerc/laconicd-stack/playbooks/tmkms/run-tmkms.yml
|
||||
```
|
||||
|
||||
### Node
|
||||
|
||||
- Run these steps in the machine where the mainnet node is setup (machine 2)
|
||||
|
||||
- Stop the node deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR stop
|
||||
```
|
||||
|
||||
- Update `$DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR/config.env` with required values
|
||||
|
||||
- Start the node deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR start
|
||||
```
|
||||
|
||||
## Publish required artifacts
|
||||
|
||||
- Run the following steps in machine where the genesis file and staking amount files are generated (machine 3)
|
||||
|
||||
@ -77,6 +77,10 @@
|
||||
# Set persistent peers (comma-separated list of node IDs and addresses)
|
||||
# You can find the list of available peers in https://git.vdb.to/cerc-io/laconicd-stack/src/branch/main/node-addresses.yml
|
||||
cerc_peers: "<node-id>@<node-host>:26656,<node-id>@<node-host>:26656"
|
||||
|
||||
# Enable TMKMS
|
||||
# Setting this to true will configure the node to use TMKMS for signing blocks
|
||||
tmkms_enabled: true
|
||||
```
|
||||
|
||||
- Export the data directory and mainnet deployment directory as environment variables:
|
||||
@ -174,17 +178,16 @@
|
||||
|
||||
- Note the pubkey logged at start for comparing later with validator pubkey on chain
|
||||
|
||||
- Remove the `priv_validator_key.json` file from TMKMS machine as it is no longer required:
|
||||
|
||||
```bash
|
||||
rm -rf <path-to-priv_validator_key.json>
|
||||
```
|
||||
|
||||
### Start Node
|
||||
|
||||
- Run the following steps in the machine where the validator node is setup (machine 2)
|
||||
|
||||
- Enable TMKMS in the laconicd node configuration:
|
||||
|
||||
```bash
|
||||
# Set TMKMS_ENABLED to true in the node's config.env
|
||||
echo "TMKMS_ENABLED=true" >> $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR/config.env
|
||||
```
|
||||
|
||||
- Start the laconicd node:
|
||||
|
||||
```bash
|
||||
@ -263,6 +266,46 @@
|
||||
|
||||
NOTE: Store it safely offline in case of an emergency
|
||||
|
||||
## Update config
|
||||
|
||||
- Run following steps to update the config for TMKMS and node
|
||||
|
||||
### TMKMS
|
||||
|
||||
- Run these steps in the machine where the TMKMS service is setup (machine 4)
|
||||
|
||||
- Stop the TMKMS deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$TMKMS_DEPLOYMENT_DIR stop
|
||||
```
|
||||
|
||||
- Update `~/cerc/laconicd-stack/playbooks/tmkms/tmkms-vars.yml` with required values
|
||||
|
||||
- Run ansible playbook to run the TMKMS:
|
||||
|
||||
```bash
|
||||
ansible-playbook -i localhost, -c local ~/cerc/laconicd-stack/playbooks/tmkms/run-tmkms.yml
|
||||
```
|
||||
|
||||
### Node
|
||||
|
||||
- Run these steps in the machine where the mainnet node is setup (machine 2)
|
||||
|
||||
- Stop the node deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR stop
|
||||
```
|
||||
|
||||
- Update `$DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR/config.env` with required values
|
||||
|
||||
- Start the node deployment:
|
||||
|
||||
```bash
|
||||
laconic-so deployment --dir $DATA_DIRECTORY/$MAINNET_DEPLOYMENT_DIR start
|
||||
```
|
||||
|
||||
## Register Your Node
|
||||
|
||||
- Get your node's address:
|
||||
|
||||
@ -1,16 +1,47 @@
|
||||
# Set to true if the application supports multiple chains
|
||||
next_public_multichain: false
|
||||
|
||||
# The name of the blockchain registry
|
||||
next_public_registry_name: "laconic"
|
||||
|
||||
# URL or path to the blockchain's logo
|
||||
next_public_logo: ""
|
||||
|
||||
# The chain ID for the blockchain network
|
||||
next_public_chain_id: "laconic-mainnet"
|
||||
|
||||
# Display name for the blockchain network
|
||||
next_public_chain_display_name: "Laconic Mainnet"
|
||||
|
||||
# Comma-separated list of node addresses for the application to connect to
|
||||
next_public_node_addresses: ""
|
||||
|
||||
# The REST endpoint for the node
|
||||
node_rest_endpoint: ""
|
||||
|
||||
# The base denomination of the native token
|
||||
next_public_denom: "alnt"
|
||||
|
||||
# The display denomination of the native token
|
||||
next_public_display_denom: "ALNT"
|
||||
|
||||
# The exponent for the display denomination (e.g., 18 for 10^18).
|
||||
next_public_display_denom_exponent: 18
|
||||
|
||||
# JSON array of asset definitions, including denom units, base, name, display, and symbol
|
||||
next_public_assets: '[{"denom_units":[{"denom":"alnt","exponent":0},{"denom":"alnt","exponent":6}],"base":"alnt","name":"Laconic Token","display":"ALNT","symbol":"alnt"}]'
|
||||
|
||||
# Default gas price for transactions
|
||||
next_public_gas_price: "0.01alnt"
|
||||
|
||||
# The address prefix for the blockchain
|
||||
next_public_address_prefix: "laconic"
|
||||
|
||||
# Set to true if HTTP is enabled for the application
|
||||
next_public_is_http_enabled: false
|
||||
|
||||
# Set to true to use host network mode for the Docker container
|
||||
use_host_network: ""
|
||||
|
||||
# Domain for Dgraph service
|
||||
dgraph_domain: ""
|
||||
|
||||
@ -1,6 +1,22 @@
|
||||
# Custom moniker for the validator node
|
||||
cerc_moniker: "LaconicMainnetNode"
|
||||
|
||||
# The chain ID for the blockchain network
|
||||
cerc_chain_id: "laconic-mainnet"
|
||||
|
||||
# Minimum gas price for transactions, in ALNT (e.g., 0.001alnt)
|
||||
min_gas_price: 0.001
|
||||
|
||||
# Log level for the laconicd node (e.g., "info", "debug", "error")
|
||||
cerc_loglevel: "info"
|
||||
|
||||
# Desired key name for the validator account
|
||||
key_name: "laconic-validator"
|
||||
|
||||
# Set to true to enable TMKMS (Tendermint Key Management System) for this node
|
||||
# If true, the node will use an external TMKMS for signing validator operations
|
||||
tmkms_enabled: false
|
||||
|
||||
# The public key of the validator node. This is required for generating the genesis file
|
||||
# It should be wrapped in single quotes
|
||||
validator_pub_key: ''
|
||||
|
||||
@ -46,6 +46,7 @@
|
||||
CERC_CHAIN_ID: "{{ cerc_chain_id }}"
|
||||
MIN_GAS_PRICE: "{{ min_gas_price }}"
|
||||
CERC_LOGLEVEL: "{{ cerc_loglevel }}"
|
||||
TMKMS_ENABLED: "{{ tmkms_enabled }}"
|
||||
mode: '0777'
|
||||
|
||||
- name: Initialize laconicd node
|
||||
|
||||
@ -20,11 +20,17 @@
|
||||
state: directory
|
||||
mode: '0755'
|
||||
|
||||
- name: Check if priv_validator_key_file_path exists
|
||||
stat:
|
||||
path: "{{ priv_validator_key_file_path }}"
|
||||
register: priv_key_file
|
||||
|
||||
- name: Copy private validator key to tmkms deployment tmp directory
|
||||
copy:
|
||||
src: "{{ priv_validator_key_file_path }}"
|
||||
dest: "{{data_directory}}/{{ tmkms_deployment_dir }}/data/tmkms-data/tmp/priv_validator_key.json"
|
||||
mode: '0644'
|
||||
when: priv_key_file.stat.exists
|
||||
|
||||
- name: Create config.env for tmkms deployment
|
||||
copy:
|
||||
|
||||
@ -1,5 +1,16 @@
|
||||
# Absolute path to the node's private validator key file (e.g., /path/to/priv_validator_key.json).
|
||||
# This file is copied into the TMKMS deployment
|
||||
priv_validator_key_file_path: ""
|
||||
|
||||
# The IP address of the machine where the laconicd node is set up
|
||||
# TMKMS will connect to this IP address
|
||||
node_ip: ""
|
||||
|
||||
# The port of the laconicd node that TMKMS will connect to
|
||||
node_port: "26659"
|
||||
|
||||
# The key prefix used for account and consensus public keys in the blockchain
|
||||
key_prefix: "laconic"
|
||||
|
||||
# The chain ID for the blockchain network
|
||||
chain_id: "laconic-mainnet"
|
||||
|
||||
@ -54,6 +54,7 @@
|
||||
CERC_PEERS: "{{ cerc_peers }}"
|
||||
MIN_GAS_PRICE: "{{ min_gas_price }}"
|
||||
CERC_LOGLEVEL: "{{ cerc_loglevel }}"
|
||||
TMKMS_ENABLED: "{{ tmkms_enabled }}"
|
||||
mode: '0777'
|
||||
|
||||
- name: Ensure tmp directory exists inside laconicd-data
|
||||
|
||||
@ -1,10 +1,35 @@
|
||||
# The URL of the laconicd node's RPC endpoint (e.g., "tcp://NODE_PUBLIC_IP_ADDRESS:26657")
|
||||
node_url: ""
|
||||
|
||||
# The public key of the validator node. This is required for creating the validator on chain
|
||||
# It should be wrapped in single quotes
|
||||
validator_pub_key: ''
|
||||
|
||||
# Custom moniker for the validator node
|
||||
cerc_moniker: ""
|
||||
|
||||
# Comma-separated list of persistent peers for the laconicd node
|
||||
# You can find available peers in https://git.vdb.to/cerc-io/laconicd-stack/src/branch/main/node-addresses.yml
|
||||
cerc_peers: ""
|
||||
|
||||
# The chain ID for the blockchain network
|
||||
cerc_chain_id: "laconic-mainnet"
|
||||
|
||||
# Minimum gas price for transactions, in ALNT (e.g., 0.001alnt)
|
||||
min_gas_price: 0.001
|
||||
|
||||
# Log level for the laconicd node (e.g., "info", "debug", "error")
|
||||
cerc_loglevel: "info"
|
||||
|
||||
# Absolute path to the mainnet genesis.json file
|
||||
genesis_file: "~/cerc/laconicd-stack/config/mainnet-genesis.json"
|
||||
|
||||
# Absolute path to the staking-amount.json file
|
||||
staking_amount_file: "~/cerc/laconicd-stack/config/staking-amount.json"
|
||||
|
||||
# Desired key name for the validator account
|
||||
key_name: "laconic-validator"
|
||||
|
||||
# Set to true to enable TMKMS (Tendermint Key Management System) for this node
|
||||
# If true, the node will use an external TMKMS for signing validator operations
|
||||
tmkms_enabled: false
|
||||
|
||||
Loading…
Reference in New Issue
Block a user