-
Notifications
You must be signed in to change notification settings - Fork 499
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: CrazyMax <[email protected]>
- Loading branch information
Showing
2 changed files
with
14 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
# syntax=docker/dockerfile:1 | ||
|
||
ARG GO_VERSION=1.21.3 | ||
ARG GOLANGCI_LINT_VERSION=1.54.2 | ||
|
||
FROM golang:${GO_VERSION}-alpine | ||
RUN apk add --no-cache git gcc musl-dev | ||
RUN wget -O- -nv https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.51.1 | ||
ENV GOFLAGS="-buildvcs=false" | ||
ARG GOLANGCI_LINT_VERSION | ||
RUN wget -O- -nv https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v${GOLANGCI_LINT_VERSION} | ||
WORKDIR /go/src/github.com/docker/buildx | ||
RUN --mount=target=/go/src/github.com/docker/buildx --mount=target=/root/.cache,type=cache \ | ||
golangci-lint run | ||
RUN --mount=target=/go/src/github.com/docker/buildx \ | ||
--mount=target=/root/.cache,type=cache \ | ||
golangci-lint run |