blob: b5fe12f049f527f51a0a5c8b86b05f0f65d8d48a [file] [log] [blame]
Earl Lee2e463fb2025-04-17 11:22:22 -07001FROM golang:1.24.2-alpine3.21
2
Philip Zeyligercc3ba222025-04-23 14:52:21 -07003RUN apk add bash git make jq sqlite gcc musl-dev linux-headers npm nodejs go github-cli ripgrep fzf python3 curl vim
Earl Lee2e463fb2025-04-17 11:22:22 -07004
5ENV GOTOOLCHAIN=auto
6ENV GOPATH=/go
7ENV PATH="$GOPATH/bin:$PATH"
8
9RUN go install golang.org/x/tools/cmd/goimports@latest
10RUN go install golang.org/x/tools/gopls@latest
11RUN go install mvdan.cc/gofumpt@latest
12
David Crawshawbe10fa92025-04-18 01:16:00 -070013RUN mkdir -p /root/.cache/sketch/webui
14
Philip Zeyligercc3ba222025-04-23 14:52:21 -070015RUN apk add --no-cache build-base || true
Earl Lee2e463fb2025-04-17 11:22:22 -070016
17ARG GIT_USER_EMAIL
18ARG GIT_USER_NAME
19
20RUN git config --global user.email "$GIT_USER_EMAIL" && \
21 git config --global user.name "$GIT_USER_NAME"
22
Philip Zeyligercc3ba222025-04-23 14:52:21 -070023LABEL sketch_context="f20a1b665182f3a8a94fe3e1e2042ee1d820fe00af69c72989146e26de9569ba"
Earl Lee2e463fb2025-04-17 11:22:22 -070024COPY . /app
25
26WORKDIR /app
27RUN if [ -f go.mod ]; then go mod download; fi
28
29CMD ["/bin/sketch"]