From 5c951b3a6d4c55adbe2577d6dab92f824153946a Mon Sep 17 00:00:00 2001 From: jabuxas Date: Fri, 18 Oct 2024 11:26:43 -0300 Subject: [PATCH] build: remove unecessary files in final image These aren't needed anymore because we started embedding `static` and `templates` directly into the binary, so that makes it easier to: 1. Distribute 2. Setup 3. Run --- Dockerfile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 87f084f..14476e6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,8 +4,8 @@ WORKDIR /app COPY go.mod go.sum ./ +# this is needed because we embed these files into the binary COPY static/ ./static/ - COPY templates/ ./templates RUN go mod download @@ -17,7 +17,5 @@ RUN CGO_ENABLED=0 GOOS=linux go build -o /abyss FROM scratch COPY --from=builder /abyss /abyss -COPY --from=builder /app/static /static -COPY --from=builder /app/templates /templates CMD ["/abyss"]