From 2f2e2d67491a633f7bcb5e77d368d3ea6ef0397f Mon Sep 17 00:00:00 2001 From: roy-dydx <133032749+roy-dydx@users.noreply.github.com> Date: Mon, 19 Aug 2024 15:46:08 -0400 Subject: [PATCH] allow configuring full preupgrade version name (#2108) (cherry picked from commit 5998dfc227d8adbe2d1ca2b4c55eb7431af2d48a) --- protocol/testing/containertest/containertest.sh | 2 +- protocol/testing/version/README.md | 6 +++++- protocol/testing/version/VERSION_FULL_NAME_PREUPGRADE | 1 + protocol/testing/version/version.sh | 3 ++- 4 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 protocol/testing/version/VERSION_FULL_NAME_PREUPGRADE diff --git a/protocol/testing/containertest/containertest.sh b/protocol/testing/containertest/containertest.sh index b7680e5800..2013200e79 100755 --- a/protocol/testing/containertest/containertest.sh +++ b/protocol/testing/containertest/containertest.sh @@ -169,7 +169,7 @@ download_preupgrade_binary() { exit 1 ;; esac - tar_url="https://github.com/dydxprotocol/v4-chain/releases/download/protocol%2F$PREUPGRADE_VERSION/dydxprotocold-$PREUPGRADE_VERSION-linux-$url_arch.tar.gz" + tar_url="https://github.com/dydxprotocol/v4-chain/releases/download/protocol%2F$PREUPGRADE_VERSION_FULL_NAME/dydxprotocold-$PREUPGRADE_VERSION_FULL_NAME-linux-$url_arch.tar.gz" tar_path='/tmp/dydxprotocold/dydxprotocold.tar.gz' mkdir -p /tmp/dydxprotocold curl -vL $tar_url -o $tar_path diff --git a/protocol/testing/version/README.md b/protocol/testing/version/README.md index 4a6f2b1d22..626340b415 100644 --- a/protocol/testing/version/README.md +++ b/protocol/testing/version/README.md @@ -1 +1,5 @@ -This directory contains files to configure version names used for upgrade tests and internal nodes. These versions are used for things such as upgrade proposals and cosmovisor directory names. When updating tests and images for a new version, most of the time you just need to change the `VERSION_CURRENT` and `VERSION_PREUPGRADE` files. +This directory contains files to configure version names used for upgrade tests and internal nodes. These versions are used for things such as upgrade proposals and cosmovisor directory names. When updating tests and images for a new version, most of the time you just need to change the `VERSION_CURRENT`, `VERSION_PREUPGRADE`, and `VERSION_FULL_NAME_PREUPGRADE` files. + +`VERSION_CURRENT` is the upgrade name for the current version. e.g. v6.0.0 is the upgrade name for v6.0.0, v6.0.1, v6.0.0-rc0, etc. +`VERSION_PREUPGRADE` is the upgrade name for the preupgrade version. e.g. v6.0.0 is the upgrade name for v6.0.0, v6.0.1, v6.0.0-rc0, etc. +`VERSION_FULL_NAME_PREUPGRADE` is the fully qualified preupgrade version name. This is used in the download url. e.g. v6.0.0-rc0. diff --git a/protocol/testing/version/VERSION_FULL_NAME_PREUPGRADE b/protocol/testing/version/VERSION_FULL_NAME_PREUPGRADE new file mode 100644 index 0000000000..b42fc5cc5d --- /dev/null +++ b/protocol/testing/version/VERSION_FULL_NAME_PREUPGRADE @@ -0,0 +1 @@ +v5.2.2 \ No newline at end of file diff --git a/protocol/testing/version/version.sh b/protocol/testing/version/version.sh index f7886f8c31..6465b7f6ee 100755 --- a/protocol/testing/version/version.sh +++ b/protocol/testing/version/version.sh @@ -1,7 +1,8 @@ #!/bin/bash CURRENT_VERSION=$(