# syntax=docker.io/docker/dockerfile:1.3@sha256:42399d4635eddd7a9b8a24be879d2f9a930d0ed040a61324cfdf59ef1357b3b2
FROM docker.io/golang:1.20.8-bullseye@sha256:2db41d88870617e0f43e7e1f304649eb4563706e3c4d25a624e43e83299fb822

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
