Fix helm collator image build

Change-Id: Iee6f664c826ebfb22307bda9fd26a61b2ff60079
This commit is contained in:
Pallav Gupta 2021-06-10 09:46:56 -07:00
parent e9c6cb0419
commit 8e34004cad
3 changed files with 9 additions and 9 deletions

View File

@ -23,7 +23,7 @@ DOCKER_REGISTRY ?= quay.io
IMAGE_PREFIX ?= airshipit
IMAGE_TAG ?= latest
DISTRO ?= debian_stable
CHARTS ?= \"$(cat "config/charts.yaml")\"
CHARTS ?= config/charts.yaml
IMAGE := ${DOCKER_REGISTRY}/${IMAGE_PREFIX}/${IMAGE_NAME}:${IMAGE_TAG}
SH_TO_CHECK := $(wildcard files/*.sh )
PROXY ?= http://proxy.foo.com:8000
@ -76,7 +76,7 @@ build_collator:
ifeq ($(IMAGE_ID), none)
ifeq ($(USE_PROXY), true)
./build-image-make.sh \
config/charts.yaml \
$(CHARTS) \
$(IMAGE_NAME) \
$(IMAGE) \
$(LABEL) \
@ -86,7 +86,7 @@ ifeq ($(USE_PROXY), true)
$(NO_PROXY)
else
./build-image-make.sh \
config/charts.yaml \
$(CHARTS) \
$(IMAGE_NAME) \
$(IMAGE) \
$(LABEL) \

View File

@ -5,7 +5,7 @@
if [[ $# < 5 ]]; then
echo "usage:"
echo " $0 \\\n"
echo " <charts filename> \\\n"
echo " <charts file> \\\n"
echo " <image name> \\\n"
echo " <image uri> \\\n"
echo " <label> \\\n"
@ -46,7 +46,7 @@ docker build . \
$(date --rfc-3339=seconds --utc)" \
--label "org.opencontainers.image.title=${IMAGE_NAME}" \
--force-rm=true \
--build-arg "CHARTS=\"$(cat "${CHARTS}")\"" \
--build-arg "CHARTS=$(cat "${CHARTS}")" \
--build-arg http_proxy=${PROXY} \
--build-arg https_proxy=${PROXY} \
--build-arg HTTP_PROXY=${PROXY} \
@ -65,6 +65,6 @@ docker build . \
$(date --rfc-3339=seconds --utc)" \
--label "org.opencontainers.image.title=${IMAGE_NAME}" \
--force-rm=true \
--build-arg "CHARTS=\"$(cat "${CHARTS}")\"" \
--build-arg "CHARTS=$(cat "${CHARTS}")" \
--build-arg GIT_COMMIT=${COMMIT}
fi
fi

View File

@ -3,7 +3,7 @@
set -xe
if [[ $# != 1 ]]; then
printf "usage: $0 <filename>\n"
printf "usage: $0 <charts file>\n"
exit 1
fi
@ -14,4 +14,4 @@ IMAGE_TAG="${IMAGE_TAG:-latest}"
image=${DOCKER_REGISTRY}/${IMAGE_PREFIX}/${IMAGE_NAME}:${IMAGE_TAG}
echo "Building the ${image}"
docker build . -t $image --build-arg "CHARTS=\"$(cat "$1")\""
docker build . -t $image --build-arg "CHARTS=$(cat "$1")"