monitor-armada-app/monitor-helm-elastic/debian/dl_hook

26 lines
789 B
Bash
Executable File

#!/bin/bash
set -x
PKG_BUILD_NAME=$1
PKG_BUILD_ROOT=$(realpath `pwd`/${PKG_BUILD_NAME})
PKG_DIR="monitor-helm-elastic"
STX_BASE=$(realpath ${MY_REPO}/stx)
SRC=$(realpath ${STX_BASE}/monitor-armada-app/${PKG_DIR})
mkdir -p ${PKG_BUILD_ROOT}
pushd ${PKG_BUILD_ROOT}
# Local mirror workaround until CGCS_BASE mirror is supported.
STX_MIRROR=$(realpath "/import/mirrors/starlingx")
# Download monitor helm elastic chart source package.
ELASTIC_PKG="helm-charts-elastic-945017287598479ba8653d9baf3ff26f7fe31e50.tar.gz"
ELASTIC_SRC_PATH=$(realpath ${STX_MIRROR}/downloads/${ELASTIC_PKG})
cp ${ELASTIC_SRC_PATH} ${PKG_BUILD_ROOT}
# Extract the monitor helm elastic chart tar file.
tar xfzvv ${ELASTIC_PKG}
# Copy source files to the build directory.
cp -pr ${SRC}/files/* ${PKG_BUILD_ROOT}