diff --git a/stack-orchestrator/stacks/laconic-console/README.md b/stack-orchestrator/stacks/laconic-console/README.md index 12db5ec..8919c3e 100644 --- a/stack-orchestrator/stacks/laconic-console/README.md +++ b/stack-orchestrator/stacks/laconic-console/README.md @@ -35,7 +35,7 @@ Instructions for running laconic registry CLI and console * Create a spec file for the deployment: ```bash - laconic-so --stack /home/prathamesh/deepstack/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console deploy init --output laconic-console-spec.yml + laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console deploy init --output laconic-console-spec.yml ``` * Edit `network` in the spec file to map container ports to host ports as required: @@ -104,7 +104,7 @@ Instructions for running laconic registry CLI and console ```bash # Example - laconic-so --dir laconic-console-deployment deploy exec cli "laconic registry status" + laconic-so deployment --dir laconic-console-deployment deploy exec cli "laconic registry status" ``` ## Check status diff --git a/stack-orchestrator/stacks/testnet-laconicd/README.md b/stack-orchestrator/stacks/testnet-laconicd/README.md index 8511c6a..dd5fbd1 100644 --- a/stack-orchestrator/stacks/testnet-laconicd/README.md +++ b/stack-orchestrator/stacks/testnet-laconicd/README.md @@ -1,4 +1,4 @@ -# laconicd-testnet +# testnet-laconicd Instructions for running a laconicd testnet full node and joining as a validator @@ -25,18 +25,29 @@ Instructions for running a laconicd testnet full node and joining as a validator * Clone required repositories: ```bash + # laconicd laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/testnet-laconicd setup-repositories + + # laocnic cli and console + laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console setup-repositories ``` * Build the container images: ```bash + # laconicd laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/testnet-laconicd build-containers + + # laocnic cli and console + laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console build-containers ``` This should create the following docker images locally: * `cerc/laconic2d` + * `cerc/laconic2-registry-cli` + * `cerc/webapp-base` + * `cerc/laconic-console-host` ## Create a deployment @@ -44,11 +55,14 @@ Instructions for running a laconicd testnet full node and joining as a validator ```bash laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/testnet-laconicd deploy init --output testnet-laconicd-spec.yml + + laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console deploy init --output laconic-console-spec.yml ``` -* Edit `network` in the spec file to map container ports to host ports as required: +* Edit `network` in both the spec files to map container ports to host ports as required: ```bash + # testnet-laconicd-spec.yml ... network: ports: @@ -59,12 +73,24 @@ Instructions for running a laconicd testnet full node and joining as a validator - '9473:9473' - '9090:9090' - '1317:1317' + + # laconic-console-spec.yml + ... + network: + ports: + laconic-console: + - '8080:80' ``` -* Create a deployment from the spec file: +* Create deployments from the spec files: ```bash laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/testnet-laconicd deploy create --spec-file testnet-laconicd-spec.yml --deployment-dir testnet-laconicd-deployment + + laconic-so --stack ~/cerc/testnet-laconicd-stack/stack-orchestrator/stacks/laconic-console deploy create --spec-file laconic-console-spec.yml --deployment-dir laconic-console-deployment + + # Place them both in the same namespace (cluster) + cp testnet-laconicd-deployment/deployment.yml laconic-console-deployment/deployment.yml ``` * Copy over the published testnet genesis file (`.json`) to data directory in deployment (`testnet-laconicd-deployment/data/laconicd-data/tmp`): @@ -77,7 +103,7 @@ Instructions for running a laconicd testnet full node and joining as a validator ## Configuration -* Inside the deployment directory, open `config.env` file and set following env variables: +* Inside the `testnet-laconicd-deployment` deployment directory, open `config.env` file and set following env variables: ```bash # Comma separated list of nodes to keep persistent connections to @@ -96,10 +122,31 @@ Instructions for running a laconicd testnet full node and joining as a validator CERC_LOGLEVEL= ``` -## Start the deployment +* Inside the `laconic-console-deployment` deployment directory, open `config.env` file and set following env variables: + + ```bash + # CLI configuration + + # laconicd chain id (default: laconic_9000-1) + CERC_LACONICD_CHAIN_ID= + + # Gas limit for txs (default: 200000) + CERC_LACONICD_GAS= + + # Max fees for txs (default: 200000photon) + CERC_LACONICD_FEES= + + # Console configuration + + # Laconicd (hosted) GQL endpoint (default: http://localhost:9473) + LACONIC_HOSTED_ENDPOINT= + ``` + +## Start the deployments ```bash laconic-so deployment --dir testnet-laconicd-deployment start +laconic-so deployment --dir laconic-console-deployment start ``` ## Check status @@ -122,6 +169,15 @@ laconic-so deployment --dir testnet-laconicd-deployment start # `catching_up: false` indicates that node is completely synced ``` +* View the laconic console at + +* Use the cli service for registry CLI operations: + + ```bash + # Example + laconic-so deployment --dir laconic-console-deployment deploy exec cli "laconic registry status" + ``` + ## Join as testnet validator * Create / import a new key pair: @@ -181,7 +237,7 @@ laconic-so deployment --dir testnet-laconicd-deployment start ## Clean up -* Stop all services running in the background: +* Stop all `testnet-laconicd` services running in the background: ```bash # Stop the docker containers @@ -197,3 +253,5 @@ laconic-so deployment --dir testnet-laconicd-deployment start # Remove deployment directory (deployment will have to be recreated for a re-run) rm -r testnet-laconicd-deployment ``` + +* For `laconic-console`, see [laconic-console clean up](../laconic-console/README.md#clean-up)