Move docker dep commands to earlier in the build

This will let Docker cache the results of the vendor dependencies.
Making re-builds during testing faster.

Also clean-up spurious test & rm in ./configure
This commit is contained in:
Daniel Kimsey
2019-07-15 10:00:34 -05:00
parent d7e88a4718
commit 816c2a6da9
5 changed files with 14 additions and 6 deletions
+4 -1
View File
@@ -7,11 +7,14 @@ RUN curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.s
# Copy sources
WORKDIR $GOPATH/src/github.com/pusher/oauth2_proxy
COPY . .
# Fetch dependencies
COPY Gopkg.toml Gopkg.lock ./
RUN dep ensure --vendor-only
# Now pull in our code
COPY . .
# Build binary and make sure there is at least an empty key file.
# This is useful for GCP App Engine custom runtime builds, because
# you cannot use multiline variables in their app.yaml, so you have to