From c019ec5a0f10b81673e0cf29da3df4e8404bf21e Mon Sep 17 00:00:00 2001 From: Yujun Zhang Date: Thu, 7 Dec 2017 10:56:41 -0800 Subject: Allow building docker image from specified path Change-Id: Iab40fc2c719050d36a614fe529ca22634b59b7bc Signed-off-by: Yujun Zhang --- jjb/releng/opnfv-docker.sh | 6 ++++-- jjb/releng/opnfv-docker.yml | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'jjb') diff --git a/jjb/releng/opnfv-docker.sh b/jjb/releng/opnfv-docker.sh index 9ba6e2bcc..7f646f1d9 100644 --- a/jjb/releng/opnfv-docker.sh +++ b/jjb/releng/opnfv-docker.sh @@ -61,7 +61,9 @@ done # Remove the existing containers and images before building remove_containers_images -cd "$WORKSPACE/$DOCKER_DIR" || exit 1 +DOCKER_PATH=$WORKSPACE/$DOCKER_DIR + +cd $DOCKER_PATH || exit 1 HOST_ARCH="$(uname -m)" #If there is a patch for other arch then x86, apply the patch and #replace Dockerfile file @@ -108,7 +110,7 @@ echo "--------------------------------------------------------" echo cmd="docker build --no-cache -t $DOCKER_REPO_NAME:$DOCKER_TAG --build-arg BRANCH=$BUILD_BRANCH $ARCH_BUILD_ARG - -f $DOCKERFILE ." + -f $DOCKERFILE $DOCKER_PATH" echo ${cmd} ${cmd} diff --git a/jjb/releng/opnfv-docker.yml b/jjb/releng/opnfv-docker.yml index 49b3fde2c..f23594ead 100644 --- a/jjb/releng/opnfv-docker.yml +++ b/jjb/releng/opnfv-docker.yml @@ -61,6 +61,8 @@ <<: *other-receivers - 'qtip': project: 'qtip' + dockerdir: '.' + dockerfile: 'docker/Dockerfile' <<: *master <<: *other-receivers - 'storperf-master': -- cgit 1.2.3-korg