14 lines
536 B
Docker
14 lines
536 B
Docker
# syntax=docker.io/docker/dockerfile:1.3@sha256:42399d4635eddd7a9b8a24be879d2f9a930d0ed040a61324cfdf59ef1357b3b2
|
|
FROM docker.io/golang:1.20.10-bullseye@sha256:082569b3303b164cc4a7c88ac59b19b69c1a5d662041ac0dca046ac239632442
|
|
|
|
RUN useradd -u 1000 -U -m -d /home/lint lint
|
|
USER 1000
|
|
WORKDIR /home/lint
|
|
|
|
# install goimports
|
|
RUN go install golang.org/x/tools/cmd/goimports@latest
|
|
|
|
# install golangci-lint
|
|
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | \
|
|
sh -s -- -b $(go env GOPATH)/bin v1.52.2
|