Skip to content

Commit

Permalink
CNCLI 5.1.0 update (#1480)
Browse files Browse the repository at this point in the history
  • Loading branch information
rdlrt committed Aug 8, 2022
1 parent 4e07443 commit 7db2879
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/cnode-helper-scripts/cncli.sh
Expand Up @@ -181,7 +181,7 @@ cncliInit() {

[[ ! -f "${CNCLI}" ]] && echo -e "\nERROR: failed to locate cncli executable, please install with 'prereqs.sh'\n" && exit 1
CNCLI_VERSION="v$(cncli -V | cut -d' ' -f2)"
if ! versionCheck "2.1.0" "${CNCLI_VERSION}"; then echo "ERROR: cncli ${CNCLI_VERSION} installed, minimum required version is 2.1.0, please upgrade to latest version!"; exit 1; fi
if ! versionCheck "5.1.0" "${CNCLI_VERSION}"; then echo "ERROR: cncli ${CNCLI_VERSION} installed, minimum required version is 5.1.0, please upgrade to latest version!"; exit 1; fi

[[ -z "${CNCLI_DIR}" ]] && CNCLI_DIR="${CNODE_HOME}/guild-db/cncli"
if ! mkdir -p "${CNCLI_DIR}" 2>/dev/null; then echo "ERROR: Failed to create CNCLI DB directory: ${CNCLI_DIR}"; exit 1; fi
Expand Down Expand Up @@ -209,7 +209,7 @@ cncliInit() {
#################################

cncliSync() {
${CNCLI} sync --host "${CNODE_HOST}" --network-magic "${NWMAGIC}" --port "${CNODE_PORT}" --db "${CNCLI_DB}"
${CNCLI} sync --host "${CNODE_HOST}" --network-magic "${NWMAGIC}" --port "${CNODE_PORT}" --db "${CNCLI_DB}" --shelley-genesis-hash "${GENESIS_HASH}"
}

#################################
Expand Down
1 change: 1 addition & 0 deletions scripts/cnode-helper-scripts/env
Expand Up @@ -898,6 +898,7 @@ else
[[ ! -f "${ALONZO_GENESIS_JSON}" ]] && echo "Byron genesis file not found: ${ALONZO_GENESIS_JSON}" && return 1
[[ ! -f "${BYRON_GENESIS_JSON}" ]] && echo "Byron genesis file not found: ${BYRON_GENESIS_JSON}" && return 1
[[ ! -f "${GENESIS_JSON}" ]] && echo "Shelley genesis file not found: ${GENESIS_JSON}" && return 1
GENESIS_HASH="$(${CCLI} genesis hash --genesis "${GENESIS_JSON}")"
PROTOCOL="${CONFIG_CONTENTS[3]}"
fi
Expand Down

0 comments on commit 7db2879

Please sign in to comment.