From ed95f5350da53c59977e24d5a1a0e8e4ec73b26f Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Tue, 17 Sep 2024 16:26:26 +0530 Subject: [PATCH] Refactor instructions --- ops/deployments-from-scratch.md | 2 +- testnet-nitro-node.md | 25 ++++++++++++++++--------- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/ops/deployments-from-scratch.md b/ops/deployments-from-scratch.md index 2415bad..e08dbaf 100644 --- a/ops/deployments-from-scratch.md +++ b/ops/deployments-from-scratch.md @@ -24,7 +24,7 @@ * On deployments machine(s): - * laconic-so: see [installation](https://git.vdb.to/cerc-io/testnet-ops/src/branch/main/stack-orchestrator-setup/README.md) + * laconic-so: see [installation](https://git.vdb.to/cerc-io/testnet-ops/src/branch/main/stack-orchestrator-setup/README.md#setup-stack-orchestrator)
L2 Optimism diff --git a/testnet-nitro-node.md b/testnet-nitro-node.md index 1426f87..a887ff6 100644 --- a/testnet-nitro-node.md +++ b/testnet-nitro-node.md @@ -4,21 +4,23 @@ * Local: - * Ansible: see [installation](https://git.vdb.to/cerc-io/testnet-ops#installation) + * Clone the `cerc-io/testnet-ops` repository: - * yq: see [installation](https://github.com/mikefarah/yq#install) + ```bash + git clone git@git.vdb.to:cerc-io/testnet-ops.git + ``` + + * Ansible: see [installation](https://git.vdb.to/cerc-io/testnet-ops#installation) * On deployment machine: - * laconic-so: see [installation](https://git.vdb.to/cerc-io/testnet-ops/src/branch/main/stack-orchestrator-setup/README.md) + * laconic-so: see [installation](https://git.vdb.to/cerc-io/testnet-ops/src/branch/main/stack-orchestrator-setup/README.md#setup-stack-orchestrator) ## Setup -* On your local machine, clone the `cerc-io/testnet-ops` repository: +* Move to `nitro-nodes-setup` : ```bash - git clone git@git.vdb.to:cerc-io/testnet-ops.git - cd testnet-ops/nitro-nodes-setup ``` @@ -70,7 +72,7 @@ * Update the target dir in `setup-vars.yml`: ```bash - # Set path to desired deployments dir + # Set path to desired deployments dir (under your user) DEPLOYMENTS_DIR= sed -i "s|^nitro_directory:.*|nitro_directory: $DEPLOYMENTS_DIR/nitro-node|" setup-vars.yml @@ -92,7 +94,7 @@ Nitro nodes can be run using Ansible either locally or on a remote machine; foll ### On Remote Host -* Create a new `hosts.ini` file: +* In `testnet-ops/nitro-nodes-setup`, create a new `hosts.ini` file: ```bash cp ../hosts.example.ini hosts.ini @@ -101,7 +103,7 @@ Nitro nodes can be run using Ansible either locally or on a remote machine; foll * Edit the [`hosts.ini`](./hosts.ini) file to run the playbook on a remote machine: ```ini - [deployment_host] + [] ansible_host= ansible_user= ansible_ssh_common_args='-o ForwardAgent=yes' ``` @@ -115,6 +117,8 @@ Nitro nodes can be run using Ansible either locally or on a remote machine; foll ```bash ansible all -m ping -i hosts.ini -k + # If using password based authentication, enter the ssh password on prompt; otherwise, leave it blank + # Expected output: # | SUCCESS => { @@ -130,6 +134,9 @@ Nitro nodes can be run using Ansible either locally or on a remote machine; foll ```bash LANG=en_US.utf8 ansible-playbook -i hosts.ini run-nitro-nodes.yml --extra-vars='{ "target_host": "nitro_host"}' --user $USER -kK + + # If using password based authentication, enter the ssh password on prompt; otherwise, leave it blank + # Enter the sudo password as "BECOME password" on prompt ``` ### Check Deployment Status