Skip to content
This repository was archived by the owner on Feb 1, 2022. It is now read-only.
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
3 changes: 1 addition & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM golang:1.11.4 as builder
FROM golang:1.12.17 as builder

ENV GO111MODULE=on

Expand All @@ -8,7 +8,6 @@ WORKDIR /go/src/github.com/kubeflow/xgboost-operator

COPY go.mod .
COPY go.sum .
# COPY vendor/ vendor/

RUN go mod download

Expand Down
3 changes: 2 additions & 1 deletion build_image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@ set -ex
DOCKERFILE=$1
CONTEXT_DIR=$(dirname "$DOCKERFILE")
IMAGE=$2
TIMEOUT=30m

cd $CONTEXT_DIR
TAG=$(git describe --tags --always --dirty)

gcloud auth activate-service-account --key-file=${GOOGLE_APPLICATION_CREDENTIALS}

echo "Building ${IMAGE} using gcloud build"
gcloud builds submit --tag=${IMAGE}:${TAG} --project=${GCP_PROJECT} .
gcloud builds submit --tag=${IMAGE}:${TAG} --project=${GCP_PROJECT} --timeout=${TIMEOUT} .
echo "Finished building ${IMAGE}:${TAG}"