kube-explorer/scripts/download
2024-09-27 17:37:50 +08:00

23 lines
625 B
Bash
Executable File

#!/bin/bash
source $(dirname $0)/version
cd "$(dirname $0)/.." || exit 1;
if [[ "$(uname)" == "Darwin" ]]; then
TAR_CMD="gtar"
else
TAR_CMD="tar"
fi
rm -rf internal/ui/ui/*
mkdir -p internal/ui/ui/dashboard
cd internal/ui/ui/dashboard || exit 1;
curl -sL https://pandaria-dashboard-ui.s3.ap-southeast-2.amazonaws.com/release-2.9-cn/kube-explorer-ui/${CATTLE_DASHBOARD_UI_VERSION}.tar.gz | $TAR_CMD xvzf - --strip-components=2
cp index.html ../index.html
mkdir ../api-ui
cd ../api-ui || exit 1;
curl -sL https://releases.rancher.com/api-ui/${CATTLE_API_UI_VERSION}.tar.gz | $TAR_CMD xvzf - --strip-components=1