From 45bb83cff54a519ba2762b9be2014eeb2f0e5097 Mon Sep 17 00:00:00 2001 From: jermy Date: Sun, 25 Feb 2024 20:00:20 +0800 Subject: [PATCH 1/3] add dist/deploy-release.sh --- dist/deploy-release.sh | 51 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100755 dist/deploy-release.sh diff --git a/dist/deploy-release.sh b/dist/deploy-release.sh new file mode 100755 index 000000000..88058c5bb --- /dev/null +++ b/dist/deploy-release.sh @@ -0,0 +1,51 @@ +#!/usr/bin/env bash +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Download hugegraph-server and hugegraph-toolcahain, then start them: +# hugegraph-server and hugegraph-hubble + +set -e + +RELEASE_VERSION=$1 # like 1.2.0 +RELEASE_VERSION=${RELEASE_VERSION:?"Please input the release version, like 1.2.0"} + +DOWNLOAD_URL_PREFIX="https://downloads.apache.org/incubator/hugegraph" +SERVER_TAR="apache-hugegraph-incubating-${RELEASE_VERSION}.tar.gz" +TOOLCHAIN_TAR="apache-hugegraph-toolchain-incubating-${RELEASE_VERSION}.tar.gz" + +echo "download hugegraph tars from $DOWNLOAD_URL_PREFIX..." +if [[ ! -f "${SERVER_TAR}" ]]; then + wget "${DOWNLOAD_URL_PREFIX}/${RELEASE_VERSION}/${SERVER_TAR}" + tar -xzvf "${SERVER_TAR}" +fi +if [[ ! -f "${TOOLCHAIN_TAR}" ]]; then + wget "${DOWNLOAD_URL_PREFIX}/${RELEASE_VERSION}/${TOOLCHAIN_TAR}" + tar -xzvf ${TOOLCHAIN_TAR} +fi + +echo "start hugegraph-server..." +cd $(echo "./*hugegraph-incubating*${RELEASE_VERSION}") +bin/stop-hugegraph.sh +bin/init-store.sh +sleep 3 +bin/start-hugegraph.sh +cd .. + +echo "start hugegraph-hubble..." +cd $(echo "./*toolchain*${RELEASE_VERSION}/*hubble*${RELEASE_VERSION}") +bin/stop-hubble.sh +bin/start-hubble.sh From 8184501d262b684717e3ee6d270b9acabaae32db Mon Sep 17 00:00:00 2001 From: Jermy Li Date: Sun, 17 Mar 2024 18:42:06 +0800 Subject: [PATCH 2/3] Update deploy-release.sh --- dist/deploy-release.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dist/deploy-release.sh b/dist/deploy-release.sh index 88058c5bb..28b53f391 100755 --- a/dist/deploy-release.sh +++ b/dist/deploy-release.sh @@ -38,8 +38,7 @@ if [[ ! -f "${TOOLCHAIN_TAR}" ]]; then fi echo "start hugegraph-server..." -cd $(echo "./*hugegraph-incubating*${RELEASE_VERSION}") -bin/stop-hugegraph.sh +cd ./*hugegraph-incubating*${RELEASE_VERSION} bin/init-store.sh sleep 3 bin/start-hugegraph.sh @@ -47,5 +46,4 @@ cd .. echo "start hugegraph-hubble..." cd $(echo "./*toolchain*${RELEASE_VERSION}/*hubble*${RELEASE_VERSION}") -bin/stop-hubble.sh bin/start-hubble.sh From 197548bba3718e472ebecaf658c335f4d420e924 Mon Sep 17 00:00:00 2001 From: Jermy Li Date: Sun, 17 Mar 2024 18:43:22 +0800 Subject: [PATCH 3/3] Update deploy-release.sh --- dist/deploy-release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dist/deploy-release.sh b/dist/deploy-release.sh index 28b53f391..b3de9a0b2 100755 --- a/dist/deploy-release.sh +++ b/dist/deploy-release.sh @@ -45,5 +45,5 @@ bin/start-hugegraph.sh cd .. echo "start hugegraph-hubble..." -cd $(echo "./*toolchain*${RELEASE_VERSION}/*hubble*${RELEASE_VERSION}") +cd ./*toolchain*${RELEASE_VERSION}/*hubble*${RELEASE_VERSION} bin/start-hubble.sh