diff --git a/.gitignore b/.gitignore index f37fe8b7..a914259d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,10 @@ bin debug.test .vscode +.idea /vendor/ /tmp/ /.tools/ *.tmp test.yaml -coverage.txt \ No newline at end of file +coverage.txt diff --git a/Dockerfile b/Dockerfile index fe257695..e793b95f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ ARG BASEIMAGE=gcr.io/distroless/static:nonroot ARG BASE_ALPINE=alpine:3.14 -ARG GO_VERSION=1.16.9 +ARG GO_VERSION=1.16.12 # ------- # Builder @@ -11,8 +11,11 @@ ARG VCS_REF=noref ARG BUILD_SUB_TARGET WORKDIR /go/src/${PACKAGE} -ADD . . + +ADD go.mod go.sum /go/src/${PACKAGE} RUN go mod download + +ADD . . RUN GIT_TAG=${VCS_REF} make build${BUILD_SUB_TARGET} # ------------