mirror of
https://github.com/nkanaev/yarr.git
synced 2025-09-13 09:55:36 +00:00
Dockerfile: cache go build directories across builds
This commit is contained in:
@@ -2,7 +2,8 @@ FROM golang:alpine3.18 AS build
|
|||||||
RUN apk add build-base git
|
RUN apk add build-base git
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN make build_linux
|
RUN --mount=type=cache,target=/root/.cache/go-build --mount=type=cache,target=/root/go/pkg \
|
||||||
|
make build_linux
|
||||||
|
|
||||||
FROM alpine:latest
|
FROM alpine:latest
|
||||||
RUN apk add --no-cache ca-certificates && \
|
RUN apk add --no-cache ca-certificates && \
|
||||||
|
Reference in New Issue
Block a user