mirror of
https://github.com/docker/docs.git
synced 2026-03-27 14:28:47 +07:00
Merge pull request #22388 from Juneezee/go-mod-mounts
docs: use bind mounts in Go Dockerfile examples
This commit is contained in:
@@ -8,9 +8,6 @@ FROM golang:${GO_VERSION}-alpine AS base
|
||||
RUN apk add --no-cache openssl
|
||||
ENV CGO_ENABLED=0
|
||||
WORKDIR /src
|
||||
COPY go.mod go.sum ./
|
||||
RUN --mount=type=cache,target=/go/pkg/mod \
|
||||
go mod download
|
||||
|
||||
FROM base AS releaser
|
||||
RUN --mount=type=bind,target=. \
|
||||
|
||||
Reference in New Issue
Block a user