From e8e9f78667ca86f21896e2fe5ea0904202bf2336 Mon Sep 17 00:00:00 2001 From: Tomáš Levora Date: Thu, 30 May 2019 09:31:24 +0200 Subject: Remove tag parameter from docker-image-collector.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Removing tag parameter from docker-image-collector.sh as it's not necessary as described in OOM-1881 Issue-ID: OOM-1885 Change-Id: Id83b396c4b994cfa659c518e3f03e704a84d65f0 Signed-off-by: Tomáš Levora --- build/creating_data/docker-images-collector.sh | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'build/creating_data/docker-images-collector.sh') diff --git a/build/creating_data/docker-images-collector.sh b/build/creating_data/docker-images-collector.sh index e13b9150..7e468c44 100755 --- a/build/creating_data/docker-images-collector.sh +++ b/build/creating_data/docker-images-collector.sh @@ -30,9 +30,9 @@ usage () { echo " " echo " This script is preparing docker images list based on kubernetes project" echo " Usage:" - echo " ./$(basename $0) []" + echo " ./$(basename $0) []" echo " " - echo " Example: ./$(basename $0) onap_3.0.2 /root/oom/kubernetes/onap" + echo " Example: ./$(basename $0) /root/oom/kubernetes/onap" echo " " echo " Dependencies: helm, python-yaml, make" echo " " @@ -61,20 +61,22 @@ create_list() { } # Configuration -TAG="${1}" -PROJECT_DIR="${2}" -LIST="${3}" +if [ "${1}" == "-h" ] || [ "${1}" == "--help" ] || [ $# -lt 1 ]; then + usage +fi + +PROJECT_DIR="${1}" +LIST="${2}" LISTS_DIR="$(readlink -f $(dirname ${0}))/../data_lists" HELM_REPO="local http://127.0.0.1:8879" +PROJECT="$(basename ${1})" -if [ "${1}" == "-h" ] || [ "${1}" == "--help" ] || [ $# -lt 2 ]; then - usage -elif [ ! -f "${PROJECT_DIR}/../Makefile" ]; then +if [ ! -f "${PROJECT_DIR}/../Makefile" ]; then echo "Wrong path to project directory entered" exit 1 elif [ -z "${LIST}" ]; then mkdir -p ${LISTS_DIR} - LIST="${LISTS_DIR}/${TAG}-docker_images.list" + LIST="${LISTS_DIR}/${PROJECT}_docker_images.list" fi if [ -e "${LIST}" ]; then @@ -82,8 +84,6 @@ if [ -e "${LIST}" ]; then MSG="$(realpath ${LIST}) already existed\nCreated backup $(realpath ${LIST}).bk\n" fi -PROJECT="$(basename ${2})" - # Setup helm if pgrep -x "helm" > /dev/null; then echo "helm is already running" -- cgit 1.2.3-korg