Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker/ingress/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ cp $DEB $ROOT/docker/ingress
cp $ROOT/bazel-bin/test/src/ingress $ROOT/docker/ingress
cp $ROOT/test/src/controller/nginx.tmpl $ROOT/docker/ingress
docker build -t ${IMAGE} $ROOT/docker/ingress || error_exit "Failed to build"
gcloud docker push ${IMAGE} || error_exit "Failed to upload docker image"
gcloud docker -- push ${IMAGE} || error_exit "Failed to upload docker image"
6 changes: 3 additions & 3 deletions script/jenkins-build-docker-slave
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ TOOLS_BUCKET=''
function update_image() {
local image="${1}"
[[ ${FORCE} == true ]] && return 0
${GCLOUD} docker pull "${image}"
${GCLOUD} docker -- pull "${image}"
local image_exists=${?}
[[ ${image_exists} -eq 0 ]] && return 1
return 0
Expand Down Expand Up @@ -75,7 +75,7 @@ if [[ "${BUILD}" == true ]]; then
run retry -n 10 docker build --build-arg TOOLS_BUCKET="${TOOLS_BUCKET}" --no-cache -t ${IMAGE} \
-f "${DOCKER_FILE}" . || error_exit "Could not build ${SLAVE}"
echo "Pushing Docker image: ${IMAGE}"
retry -n 3 ${GCLOUD} docker push "${IMAGE}" \
retry -n 3 ${GCLOUD} docker -- push "${IMAGE}" \
|| error_exit "Failed to push tag ${IMAGE}."
fi
fi
Expand All @@ -86,7 +86,7 @@ if [[ -n "${TAG}" ]]; then
retry -n 3 docker tag "${IMAGE}" ${TAG}

echo "Pushing Docker image: ${TAG}"
retry -n 3 ${GCLOUD} docker push "${TAG}" \
retry -n 3 ${GCLOUD} docker -- push "${TAG}" \
|| error_exit "Failed to push tag ${TAG}."
fi

6 changes: 3 additions & 3 deletions script/linux-build-docker
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ done
[[ -f "${DEB}" ]] || error_exit "Cannot find Debian package ${DEB}"

echo "Checking if docker image ${IMAGE} exists.."
gcloud docker pull "${IMAGE}" \
gcloud docker -- pull "${IMAGE}" \
&& { echo "Image ${IMAGE} already exists; skipping"; exit 0; }

echo "Building Endpoints Runtime docker image."
Expand Down Expand Up @@ -86,14 +86,14 @@ if [[ -n "${CONFIG}" ]]; then

echo "Pushing Custom Docker image: ${IMAGE}"
retry -n 10 -s 10 \
gcloud docker push "${IMAGE}" \
gcloud docker -- push "${IMAGE}" \
|| error_exit "Failed to upload custom Docker image to gcr."
else

echo "Pushing Docker image: ${IMAGE}"

# Try 10 times, shortest wait is 10 seconds, exponential back-off.
retry -n 10 -s 10 \
gcloud docker push "${IMAGE}" \
gcloud docker -- push "${IMAGE}" \
|| error_exit "Failed to upload Docker image to gcr."
fi
2 changes: 1 addition & 1 deletion script/release-stable
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ function tag_stable_image() {

docker_tag_f "${image}" "${stable}"

retry "${GCLOUD}" docker push "${stable}" \
retry "${GCLOUD}" docker -- push "${stable}" \
|| error_exit "ERROR: failed to push '${stable}'"
}

Expand Down
4 changes: 2 additions & 2 deletions test/bookstore/linux-build-bookstore-docker
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ done
[[ -n "${IMAGE}" ]] || error_exit "Specify required image argument via '-i'"

echo "Checking if docker image ${IMAGE} exists.."
gcloud docker pull "${IMAGE}" \
gcloud docker -- pull "${IMAGE}" \
&& echo "Image ${IMAGE} already exists; skipping" \
&& exit 0

Expand All @@ -54,5 +54,5 @@ retry -n 3 docker build --no-cache -t ${IMAGE} \
echo "Pushing Docker image: ${IMAGE}"
# Try 10 times, shortest wait is 10 seconds, exponential back-off.
retry -n 10 -s 10 \
gcloud docker push "${IMAGE}" \
gcloud docker -- push "${IMAGE}" \
|| error_exit "Failed to upload Docker image to gcr."
2 changes: 1 addition & 1 deletion test/echo/docker-remote/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ sed "s/\${PROJECT}/${PROJECT}/" ../service.json.temp > ./service.json

${GCLOUD} docker -- build --no-cache -t ${TAG} .
docker tag -f ${TAG} gcr.io/${PROJECT}/${TAG}
${GCLOUD} docker push gcr.io/${PROJECT}/${TAG}
${GCLOUD} docker -- push gcr.io/${PROJECT}/${TAG}

rm service.json

Expand Down
2 changes: 1 addition & 1 deletion test/echo/docker/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ sed "s/\${PROJECT}/${PROJECT}/" ../service.json.temp > ./service.json

docker build --no-cache -t ${TAG} .
docker tag -f ${TAG} gcr.io/${PROJECT}/${TAG}
${GCLOUD} docker push gcr.io/${PROJECT}/${TAG}
${GCLOUD} docker -- push gcr.io/${PROJECT}/${TAG}

rm service.json

Expand Down
2 changes: 1 addition & 1 deletion test/grpc/Dockerfile.temp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
# 2) cp bazel-bin/test/grpc/grpc-test-server test/grpc
# 3) IMAGE=gcr.io/endpointsv2/grpc-test-server:latest
# 4) docker build --no-cache -t "${IMAGE}" test/grpc
# 5) gcloud docker push "${IMAGE}"
# 5) gcloud docker -- push "${IMAGE}"

FROM debian:jessie

Expand Down
4 changes: 2 additions & 2 deletions test/grpc/linux-build-grpc-docker
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ done
[[ -n "${IMAGE}" ]] || error_exit "Specify required image argument via '-i'"

echo "Checking if docker image ${IMAGE} exists.."
gcloud docker pull "${IMAGE}" \
gcloud docker -- pull "${IMAGE}" \
&& { echo "Image ${IMAGE} already exists; skipping"; exit 0; }

BAZEL_TARGET="${ROOT}/bazel-bin/${TEST_SERVER_BIN}"
Expand All @@ -82,5 +82,5 @@ retry -n 3 docker build --no-cache -t "${IMAGE}" \
echo "Pushing Docker image: ${IMAGE}"
# Try 10 times, shortest wait is 10 seconds, exponential back-off.
retry -n 10 -s 10 \
gcloud docker push "${IMAGE}" \
gcloud docker -- push "${IMAGE}" \
|| error_exit "Failed to upload Docker image to gcr."
2 changes: 1 addition & 1 deletion test/transcoding/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# 2) cp bazel-bin/test/transcoding/bookstore-server test/transcoding
# 3) IMAGE=gcr.io/endpointsv2/bookstore-grpc:latest
# 4) docker build --no-cache -t "${IMAGE}" test/transcoding
# 5) gcloud docker push "${IMAGE}"
# 5) gcloud docker -- push "${IMAGE}"

FROM debian:jessie

Expand Down