From d2d0d4a1eaa91136ab305e5851c64cc07ef08bd7 Mon Sep 17 00:00:00 2001 From: Mark Sagi-Kazar Date: Sat, 23 Jan 2021 19:13:13 +0100 Subject: [PATCH] chore(docker): reorder instructions in build image Signed-off-by: Mark Sagi-Kazar --- Dockerfile | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 53f72023..8d5d7d1a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,14 @@ FROM golang:1.15.7-alpine3.13 AS builder +WORKDIR /usr/local/src/dex + +RUN apk add --no-cache --update alpine-sdk + ARG TARGETOS ARG TARGETARCH ARG TARGETVARIANT="" -WORKDIR /usr/local/src/dex - -ENV GOOS=${TARGETOS} \ - GOARCH=${TARGETARCH} \ - GOARM=${TARGETVARIANT} - -RUN apk add --no-cache --update alpine-sdk +ENV GOOS=${TARGETOS} GOARCH=${TARGETARCH} GOARM=${TARGETVARIANT} ARG GOPROXY