Go to file
Stanislav N. aka pztrn 4e1dc58611
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
More verbosive entrypoint.
2024-07-19 23:30:31 +05:00
scripts Update golang, golangci-lint, mockery, taskfile. 2024-07-07 20:38:54 +05:00
.drone.yml Initial commit. 2024-05-04 13:18:37 +05:00
.gitignore Initial commit. 2024-05-04 13:18:37 +05:00
.markdownlint.json Initial commit. 2024-05-04 13:18:37 +05:00
.yamllint Initial commit. 2024-05-04 13:18:37 +05:00
action.yml Get rid of command-args separation. 2024-07-19 23:19:23 +05:00
build_multiarch.sh Script for multiarch image. 2024-07-07 21:13:47 +05:00
build.sh Fix typo in build script (mainly for triggering CI). 2024-05-04 13:29:03 +05:00
Dockerfile Try to make it github/gitea actionable. 2024-07-19 15:11:50 +05:00
entrypoint.sh More verbosive entrypoint. 2024-07-19 23:30:31 +05:00
README.md Remove "newer mac" line from README as it is invalid now. 2024-07-07 21:18:00 +05:00

Go ToolBox

Docker image with everything you might need for developing apps in Go.

What's inside

Debian 12 (slim) is used as base image.

Binary Version Project Repo
go 1.22.5 Go
golangci-lint 1.59.1 golangci-lint External link
gofumpt 0.6.0 gofumpt External link
mockery_v2 2.43.2 mockery External link
task 3.38.0 taskfile External link
go-junit-report 2.1.0 go-junit-report External link
delve 1.22.1 delve External link

Multiarch support

This image contains versions for both amd64 (AMD/Intel CPUs and their clones) and arm64 (Rockchips, Apple Silicon and so on).

Note, that amd64 image built on my CI server, while arm64 image I building on my local machine with built_multiarch.sh for each published tag. It is because I have no separate arm64 machine (yet) and it's emulation on my server's CPU is freaking slow (imagine Linux installation is going for three whole hours!).

HOME

Home directory is /home/container.

Caching

Go's build cache resides in /home/container/.cache, GOCACHE environment variable is defined. You can mount it when needed in Dockerfile as:

RUN --mount=type=cache,target="$GOCACHE" go build

Utilities examples

JUnit report generation (for Gitlab)

go test -v 2>&1 ./... | go-junit-report -set-exit-code > unit-report.xml