From 8b2eba1426c7701ec49187fb38ec348948647ebf Mon Sep 17 00:00:00 2001 From: shreddedbacon Date: Mon, 30 Sep 2024 12:23:43 +1000 Subject: [PATCH] build: copy required go components to reduce cache invalidation --- Dockerfile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index db2f7baf..3fbb218a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,7 +10,12 @@ RUN go install github.com/a8m/envsubst/cmd/envsubst@v1.4.2 WORKDIR /app -COPY . ./ +COPY go.mod go.mod +COPY go.sum go.sum + +COPY main.go main.go +COPY cmd/ cmd/ +COPY internal/ internal/ ARG BUILD ARG GO_VER