This is an automated email from the ASF dual-hosted git repository.
liujun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo-kubernetes.git
The following commit(s) were added to refs/heads/master by this push:
new 5be8a339 feat: update realease shell scripts
new fb9d8d12 Merge pull request #116 from
yuluo-yx/1218/yuluo-fix-script-error
5be8a339 is described below
commit 5be8a3392d44d4c8351a2a1904fa1f965fcbaf8c
Author: yuluo <[email protected]>
AuthorDate: Mon Dec 18 22:19:04 2023 +0800
feat: update realease shell scripts
---
release/downloadDubbo.sh | 19 ++++++++++---------
release/downloadDubboCtl.sh | 27 ++++++++++++++-------------
2 files changed, 24 insertions(+), 22 deletions(-)
diff --git a/release/downloadDubbo.sh b/release/downloadDubbo.sh
index 4dd3cc8e..e06ee3e3 100644
--- a/release/downloadDubbo.sh
+++ b/release/downloadDubbo.sh
@@ -25,7 +25,7 @@ fi
# Determine the latest Dubbo version by version number ignoring alpha, beta,
and rc versions.
if [ "${DUBBO_VERSION}" = "" ] ; then
- DUBBO_VERSION="$(curl -sL
https://github.com/dawnzzz/dubbo-kubernetes/releases | \
+ DUBBO_VERSION="$(curl -sL https://github.com/apache/dubbo/releases | \
grep -E -o 'dubbo/([v,V]?)[0-9]*.[0-9]*.[0-9]*' | sort -V | \
tail -1 | awk -F'/' '{ print $2}')"
DUBBO_VERSION="${DUBBO_VERSION##*/}"
@@ -62,11 +62,11 @@ download_failed () {
exit 1
}
-# Downloads the dubboctl binary archive.
-tmp=$(mktemp -d /tmp/dubboctl.XXXXXX)
+# Downloads the dubbo binary archive.
+tmp=$(mktemp -d /tmp/dubbo.XXXXXX)
NAME="dubboctl-${DUBBO_VERSION}"
-ARCH_URL="https://github.com/apache/dubbo-kubernetes/releases/download/dubbo%2F${DUBBO_VERSION}/dubbo-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
+ARCH_URL="https://github.com/apache/dubbo/releases/download/dubbo%2F${DUBBO_VERSION}/dubbo-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
with_arch() {
printf "\nDownloading %s from %s ...\n" "${NAME}" "$ARCH_URL"
@@ -74,7 +74,7 @@ with_arch() {
printf "\n%s is not found, please specify a valid DUBBO_VERSION and
TARGET_ARCH\n" "$ARCH_URL"
exit 1
fi
- filename="dubboctl-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
+ filename="dubbo-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
curl -fsL -o "${tmp}/${filename}" "$ARCH_URL"
tar -xzf "${tmp}/${filename}" -C "${tmp}"
}
@@ -84,17 +84,18 @@ with_arch
printf "%s download complete!\n" "${filename}"
# setup dubboctl
-mkdir -p "$HOME/.dubboctl/bin"
-mv "${tmp}/dubboctl" "$HOME/.dubboctl/bin/dubboctl"
-chmod +x "$HOME/.dubboctl/bin/dubboctl"
+mkdir -p "$HOME/.dubbo/bin"
+mv "${tmp}/dubbo" "$HOME/.dubbo/bin/dubbo"
+chmod +x "$HOME/.dubbo/bin/dubbo"
rm -r "${tmp}"
# Print message
printf "\n"
printf "Add the dubboctl to your path with:"
printf "\n"
-printf " export PATH=\$HOME/.dubboctl/bin:\$PATH \n"
+printf " export PATH=\$HOME/.dubbo/bin:\$PATH \n"
printf "\n"
printf "Begin the Dubbo pre-installation check by running:\n"
printf "\t dubboctl x precheck \n"
printf "\n"
+
diff --git a/release/downloadDubboCtl.sh b/release/downloadDubboCtl.sh
index 509b99e0..27f5e6c0 100644
--- a/release/downloadDubboCtl.sh
+++ b/release/downloadDubboCtl.sh
@@ -23,16 +23,16 @@ else
OSEXT="linux"
fi
-# Determine the latest Dubbo version by version number ignoring alpha, beta,
and rc versions.
-if [ "${DUBBO_VERSION}" = "" ] ; then
- DUBBO_VERSION="$(curl -sL
https://github.com/dawnzzz/dubbo-kubernetes/releases | \
+# Determine the latest Dubboctl version by version number ignoring alpha,
beta, and rc versions.
+if [ "${DUBBOCTL_VERSION}" = "" ] ; then
+ DUBBOCTL_VERSION="$(curl -sL
https://github.com/apache/dubbo-kubernetes/releases | \
grep -E -o 'dubboctl/([v,V]?)[0-9]*.[0-9]*.[0-9]*' | sort -V
| \
tail -1 | awk -F'/' '{ print $2}')"
- DUBBO_VERSION="${DUBBO_VERSION##*/}"
+ DUBBOCTL_VERSION="${DUBBOCTL_VERSION##*/}"
fi
-if [ "${DUBBO_VERSION}" = "" ] ; then
- printf "Unable to get latest Dubbo version. Set DUBBO_VERSION env var and
re-run. For example: export DUBBO_VERSION=0.0.1\n"
+if [ "${DUBBOCTL_VERSION}" = "" ] ; then
+ printf "Unable to get latest Dubboctl version. Set DUBBOCTL_VERSION env var
and re-run. For example: export DUBBOCTL_VERSION=0.0.1\n"
exit 1;
fi
@@ -43,13 +43,13 @@ fi
case "${LOCAL_ARCH}" in
x86_64|amd64)
- DUBBO_ARCH=amd64
+ DUBBOCTL_ARCH=amd64
;;
armv8*|aarch64*|arm64)
- DUBBO_ARCH=arm64
+ DUBBOCTL_ARCH=arm64
;;
armv*)
- DUBBO_ARCH=armv7
+ DUBBOCTL_ARCH=armv7
;;
*)
echo "This system's architecture, ${LOCAL_ARCH}, isn't supported"
@@ -64,17 +64,17 @@ download_failed () {
# Downloads the dubboctl binary archive.
tmp=$(mktemp -d /tmp/dubboctl.XXXXXX)
-NAME="dubboctl-${DUBBO_VERSION}"
+NAME="dubboctl-${DUBBOCTL_VERSION}"
-ARCH_URL="https://github.com/apache/dubbo-kubernetes/releases/download/dubboctl%2F${DUBBO_VERSION}/dubboctl-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
+ARCH_URL="https://github.com/apache/dubbo-kubernetes/releases/download/dubboctl%2F${DUBBOCTL_VERSION}/dubboctl-${DUBBOCTL_VERSION}-${OSEXT}-${DUBBOCTL_ARCH}.tar.gz"
with_arch() {
printf "\nDownloading %s from %s ...\n" "${NAME}" "$ARCH_URL"
if ! curl -o /dev/null -sIf "$ARCH_URL"; then
- printf "\n%s is not found, please specify a valid DUBBO_VERSION and
TARGET_ARCH\n" "$ARCH_URL"
+ printf "\n%s is not found, please specify a valid DUBBOCTL_VERSION and
TARGET_ARCH\n" "$ARCH_URL"
exit 1
fi
- filename="dubboctl-${DUBBO_VERSION}-${OSEXT}-${DUBBO_ARCH}.tar.gz"
+ filename="dubboctl-${DUBBOCTL_VERSION}-${OSEXT}-${DUBBOCTL_ARCH}.tar.gz"
curl -fsL -o "${tmp}/${filename}" "$ARCH_URL"
tar -xzf "${tmp}/${filename}" -C "${tmp}"
}
@@ -98,3 +98,4 @@ printf "\n"
printf "Begin the Dubbo pre-installation check by running:\n"
printf "\t dubboctl x precheck \n"
printf "\n"
+