Tooling for linting, testing and building Go applications
- Project home
- Docker images
- Overview
- Linting tools included
- Build tools included
- Testing tools included
- Images
- Matrix images
- General build images
go-ci-oldstable-alpine-buildx86go-ci-oldstable-alpine-buildx64go-ci-stable-alpine-buildx86go-ci-stable-alpine-buildx64go-ci-unstable-alpine-buildx86go-ci-unstable-alpine-buildx64go-ci-oldstable-cgo-mingw-w64-buildx86go-ci-oldstable-cgo-mingw-w64-buildx64go-ci-stable-cgo-mingw-w64-buildx86go-ci-stable-cgo-mingw-w64-buildx64go-ci-unstable-cgo-mingw-w64-buildx86go-ci-unstable-cgo-mingw-w64-buildx64
- Mirror build images
- Release build images
- Examples / How to use these images
- Changelog
- Requirements
- References
See our GitHub repo for the latest content, to file an issue or submit improvements for review and potential inclusion into the project.
See these container image registries for the full listing of available images:
A mix of GitHub Actions / CI focused Docker container images primarily intended to simplify linting/testing/building other Go projects that I maintain. I am developing the content in the open in case it is useful to others.
Unless indicated otherwise, the following linting tools are included in the
go-ci-stable, go-ci-oldstable and go-ci-unstable images:
| Linter | Version |
|---|---|
staticcheck |
2025.1.1 (v0.6.1) |
golangci-lint |
v2.5.0 |
govulncheck |
v1.1.4 |
deadcode |
v0.38.0 |
pelletier/go-toml |
v2.2.4 |
The following build tools are included in all *-build* images except for
the *-mirror-* images:
| Build tool | Version |
|---|---|
tc-hib/go-winres |
v0.3.3 |
goreleaser/nfpm |
v2.43.3 |
choffmeister/git-describe-semver |
v0.4.0 |
The following testing tools are included in the go-ci-stable,
go-ci-oldstable and go-ci-unstable images:
| Testing tool | Version |
|---|---|
bitfield/gotestdox |
v0.2.2 |
- built from the latest version of the current stable
golangimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - intended for use in a build/test matrix of prior, current and upcoming Go releases
- ✔️ provides multiple linters
- ✔️ provides testing tools
- ❌ does not include custom build tools
- built from the latest version of the current outgoing stable
golangimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - intended for use in a build/test matrix of prior, current and upcoming Go releases
- ✔️ provides multiple linters
- ✔️ provides testing tools
- ❌ does not include custom build tools
- built from the latest available non-stable
golang:betaimage,golang:rcimage or if not recently available, the latest stablegolangimage- intended to test whether new Go versions break existing code or surface problems in existing code that current Go releases do not
- used for building and testing Go applications, both directly and via
Makefilebuilds - intended for use in a build/test matrix of prior, current and upcoming Go releases
- ✔️ provides multiple linters
- ✔️ provides testing tools
- ❌ does not include custom build tools
- used to test new or additional
golangci-lintlinters prior to inclusion in thestableandoldstablecontainer image variants- new linters as a whole may be added to multiple image variants, not just this image unless it is suspected that the new linters are highly experimental/unstable
- based on the latest version of the current outgoing stable
i386/golangalpineimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - uses musl libc instead of glibc
- supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-oldstable-alpine-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- based on the latest version of the current stable
i386/golangalpineimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - uses musl libc instead of glibc
- supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-stable-alpine-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest available non-stable (beta, rc or if not available the
latest stable) version of the
i386/golangalpineimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - uses musl libc instead of glibc
- supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-unstable-alpine-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest version of the current outgoing stable
i386/golangimage - used for building and testing Go applications, both directly and via
Makefilebuilds. - supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides Fyne toolkit build dependencies
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-oldstable-cgo-mingw-w64-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ✔️ provides Fyne toolkit build dependencies
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest version of the current stable
i386/golangimage - used for building and testing Go applications, both directly and via
Makefilebuilds. - supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides multiple custom build tools
- ✔️ provides Fyne toolkit build dependencies
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-stable-cgo-mingw-w64-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ✔️ provides Fyne toolkit build dependencies
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest available non-stable (beta, rc or if not available the
latest stable)
golangimage. - used for building and testing Go applications, both directly and via
Makefilebuilds. - supports cross-platform, cgo-enabled builds for Windows and Linux
- Windows 32-bit:
i686-w64-mingw32-gcc - Windows 64-bit:
x86_64-w64-mingw32-gcc
- Windows 32-bit:
- ✔️ provides multiple custom build tools
- ✔️ provides Fyne toolkit build dependencies
- ❌ does not include linters
- ❌ does not include testing tools
- same as
go-ci-unstable-cgo-mingw-w64-buildx86, but specific to x64 architecture - ✔️ provides multiple custom build tools
- ✔️ provides Fyne toolkit build dependencies
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest version of the
golangimage for that series- e.g., the
go-ci-mirror-build-go1.14image is built from the final release version in the 1.14 series (1.14.15)
- e.g., the
- intended to mirror the upstream
golangimage for Makefile-driven testing, linting and build tasks. - few (if any) customizations are intended for this image, instead relying on a project's Makefile or other build tool to setup the environment for tasks such as testing, linting & building source code
- ❌ does not include linters
- ❌ does not include testing tools
- ❌ does not include custom build tools
These images are intended to assist with asserting that projects build with the latest version in a specific series.
Unlike most other images, the go-ci-oldstable-mirror-build name is not the
title of an image (such as go-ci-stable), but rather an additional tag for
the latest version of the golang image for the oldstable series.
- built from the latest version of the
golangimage for theoldstableseries- e.g., if the latest
oldstableversion of the Go toolchain is 1.19.6 and 1.20.1 is the latest in thestableseries, thego-ci-oldstable-mirror-buildimage will refer to the 1.19.6 image
- e.g., if the latest
- intended to mirror the latest
oldstable(outgoing) upstreamgolangimage for Makefile-driven testing, linting and build tasks. - few (if any) customizations are intended for this image, instead relying on a project's Makefile or other build tool to setup the environment for tasks such as testing, linting & building source code
- ❌ does not include linters
- ❌ does not include testing tools
- ❌ does not include custom build tools
These images are intended to assist with asserting that projects build with
the latest version in the outgoing stable (aka, oldstable) series.
Unlike most other images, the go-ci-stable-mirror-build name is not the
title of an image (such as go-ci-stable), but rather an additional tag for
the latest version of the golang image for the stable series.
- built from the latest version of the
golangimage for the currentstableseries- e.g., if the latest
oldstableversion of the Go toolchain is 1.19.6 and 1.20.1 is the latest in thestableseries, thego-ci-stable-mirror-buildimage tag will refer to the 1.20.1 image
- e.g., if the latest
- intended to mirror the latest
stable(current) upstreamgolangimage for Makefile-driven testing, linting and build tasks. - few (if any) customizations are intended for this image, instead relying on a project's Makefile or other build tool to setup the environment for tasks such as testing, linting & building source code
- ❌ does not include linters
- ❌ does not include testing tools
- ❌ does not include custom build tools
These images are intended to assist with asserting that projects build with the latest version in the current stable series.
- built from the latest version of the current stable
golangimage. - used for building dev and stable releases of Go code
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest version of the current outgoing stable
golangimage. - used for building dev and stable releases of Go code
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
- built from the latest available non-stable
golang:betaimage,golang:rcimage or if not recently available, the latest stablegolangimage- intended to test whether new Go versions break existing code or surface problems in existing code that current Go releases do not
- used for building dev and stable releases of Go code
- ✔️ provides multiple custom build tools
- ❌ does not include linters
- ❌ does not include testing tools
For real-world examples of how these images are used, please see the workflows for these projects:
- https://github.com/atc0005/shared-project-resources/tree/master/.github/workflows
- https://github.com/atc0005/check-cert/blob/master/.github/workflows
- https://github.com/atc0005/check-vmware/blob/master/.github/workflows
- https://github.com/atc0005/check-mail/blob/master/.github/workflows
- https://github.com/atc0005/dnsc/tree/master/.github/workflows
- https://github.com/atc0005/mysql2sqlite/tree/master/.github/workflows
See the CHANGELOG.md file for the changes associated with
each release of this project.
- Docker
- for building images
make- if using the provided
Makefile
- if using the provided
- Sufficient disk space to hold build images
- 20+ GB free disk space recommended if building all images
- 10+ GB free disk space recommended if building one set of images
- Linting
- Primary
- Additional
- Build Tools
- Testing Tools
- Images