From ce644b7ff79711df35fc1af169fe4cfddd83977f Mon Sep 17 00:00:00 2001 From: lander86 <40528366+lander86@users.noreply.github.com> Date: Wed, 13 Mar 2024 20:32:26 +0100 Subject: [PATCH] Update Docs (#18) --- README.md | 5 +---- docs/MIGRATION.md | 2 +- scripts/init.sh | 6 +----- 3 files changed, 3 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 1b671a3..3c527fa 100644 --- a/README.md +++ b/README.md @@ -22,10 +22,7 @@ This repository contains all the resources for deploying a forger or rpc EVM sid ## Upgrade 1. If your project structure is 1.2.* follow the instructions here: [Migration from 1.2.* to 1.3.0](./docs/MIGRATION.md) -2. Run the [upgrade.sh](./scripts/upgrade.sh) script to upgrade the project to the new version. +2. Run the [upgrade.sh](./scripts/upgrade.sh) script to upgrade the project to the new version. Should the script prompt you to update some of the values in .env file, it is reccomended to accept all the changes unless you know what you are doing. --- - - - diff --git a/docs/MIGRATION.md b/docs/MIGRATION.md index 665f923..0de710e 100644 --- a/docs/MIGRATION.md +++ b/docs/MIGRATION.md @@ -11,7 +11,7 @@ If you are using version 1.2.* of this project, you will need to follow these st 1. Make a copy of your .env file. This file contains some secrets that you will need to keep. 2. Stop the running containers. You can use the `docker compose down` command to stop and remove the containers. **DO NOT REMOVE THE VOLUMES**. -3. Pull the new tag 1.3.0 of the project. +3. Pull the new tag 1.3.0 of the project. To do so run `git pull && git checkout 1.3.0`. 4. Run the init script in order to set up the new structure of the project. 5. When requested by the script provide the already generated SCNODE_WALLET_SEED available in the old .env file. 6. Review the new .env file and update the values if necessary. For instance RPC or REST passwords, or node names. diff --git a/scripts/init.sh b/scripts/init.sh index e8548ed..cafa79d 100755 --- a/scripts/init.sh +++ b/scripts/init.sh @@ -77,9 +77,7 @@ if ! [ -f "${ENV_FILE}" ]; then fi fi fi - - SCNODE_NET_NODENAME="ext-partner-$((RANDOM % 100000 + 1))" || fn_die "Error: could not set NODE_NAME variable for some reason. Fix it before proceeding any further. Exiting..." - + SCNODE_NET_NODENAME="ext-${role_value}-$((RANDOM % 100000 + 1))" || fn_die "Error: could not set NODE_NAME variable for some reason. Fix it before proceeding any further. Exiting..." sed -i "s/SCNODE_NET_NODENAME=.*/SCNODE_NET_NODENAME=${SCNODE_NET_NODENAME}/g" "${ENV_FILE}" fi @@ -94,7 +92,6 @@ SYMLINK_COMPOSE_FILE="${DEPLOYMENT_DIR}/docker-compose.yml" ln -sf "${COMPOSE_FILE}" "${SYMLINK_COMPOSE_FILE}" if [ "${role_value}" = "forger" ]; then - DOWNLOAD_SEED_FILE="${ROOT_DIR}/scripts/forger/seed/download_seed.sh" SYMLINK_SEED_DOWNLOAD_FILE="${DEPLOYMENT_DIR}/scripts/download_seed.sh" SEED_FILE="${ROOT_DIR}/scripts/forger/seed/seed.sh" @@ -134,7 +131,6 @@ if [ "${role_value}" = "forger" ]; then echo -e "\n\033[1m===========================\033[0m\n" else - echo -e "\n\033[1m=== Project has been initialized correctly for ${role_value} and ${network_value} ===\033[0m" echo -e "\n\033[1m=== RUNNING RPC NODE ===\033[0m\n"