Skip to content
PluginStats

portainer/golang-builder pulls statistics

By portainer (61 listings) · Docker Hub · Languages & frameworks

Utility to build Golang binaries.

View on Docker Hub Fresh · Dec 6, 2026

portainer/golang-builder has 147,980 recorded pulls on Docker Hub, an increase of 0.2% over the past 30 days, ranking #370 of 1,291 tracked listings.

Pulls
147,980
Official API · Dec 6, 2026
7-day growth
+0.0%
+65 pulls
30-day growth
+0.2%
+251 pulls
90-day growth
—
Insufficient history
Rank
#370
▼ 4 in 7 days

About portainer/golang-builder

golang-builder

Containerized build environment for compiling an executable Golang package.

Overview

One of the (many) benefits of developing with Go is that you have the option of compiling your application into a self-contained, statically-linked binary. A statically-linked binary can be run in a container with NO other dependencies which means you can create incredibly small images.

With a statically-linked binary, you could have a Dockerfile that looks something like this:

FROM scratch
COPY hello /
ENTRYPOINT ["/hello"]

Note that the base image here is the 0 byte scratch image which serves as the root layer for all Docker images. The only thing in the resulting image will be the copied binary so the total image size will be roughly the same as the binary itself.

Contrast that with using the official golang image which weighs-in at 500MB before you even copy your application into it.

The golang-builder will accept your source code, compile it into a statically-linked binary and generate a minimal Docker image containing that binary.

The implementation of the golang-builder was heavily inspired by the Create the Smallest Possible Docker Container post on the Xebia blog.

Requirements

In order for the golang-builder to work properly with your project, you need to follow a few simple conventions:

Project Structure

The golang-builder assumes that your "main" package (the package containing your executable command) is at the root of your project directory structure.

.
├─api
| ├─api.go
| └─api_test.go
├─greeting
| ├─greeting.go
| └─greeting_test.go
├─hello.go
└─hello_test.go

In the example above, the hello.go source file defines the "main" package for this project and lives at the root of the project directory structure. This project defines other packages ("api" and "greeting") but those are subdirectories off the root.

This convention is in place so that the golang-builder knows where to find the "main" package in the project structure. In a future release, we may make this a configurable option in order to support projects with different directory structures.

You can override this behaviour by specifying the path to your "main" package as a parameter to the Docker image (b sure to use the same folder prefix as the mounted directory in the container e.g. /src in this example ).

docker run --rm \
  -v "$(pwd):/src" \
  -v /var/run/docker.sock:/var/run/docker.sock \
  portainer/golang-builder /src/subfolder/main
Canonical Import Path

In addition to knowing where to find the "main" package, the golang-builder also needs to know the fully-qualified package name for your application. For the "hello" application shown above, the fully-qualified package name for the executable is "github.com/CenturyLink/hello" but there is no way to determine that just by looking at the project directory structure (during the development, the project directory would likely be mounted at $GOPATH/src/github.com/CenturyLink/hello so that the Go tools can determine the package name).

In version 1.4 of Go an annotation was introduced which allows you to identify the canonical import path as part of your source code. The annotation is a specially formatted comment that appears immediately after the package clause:

package main // import "github.com/CenturyLink/hello"

The golang-builder will read this annotation from your source code and use it to mount the source code into the proper place in the GOPATH for compilation.

Dependencies

There's a good chance that your project imports at least one third-party Go package. The golang-builder obviously needs access to any packages that you've imported in order to compile your code. By default, golang-builder will go get any packages you've imported which aren't part of your project already.

The problem with doing a go get with each build is that golang-builder may end up with versions of packages which are different than those you developed against. Depending on the stability of the packages that you are importing this may not be an issue. However, if you want to maintain strict control over your dependency versions you may want to look at the Godep tool.

If you are using Godep to manage your dependencies golang-builder will reference the packages in your Godeps/_workspace directory instead of downloading them via go get.

Dockerfile

If you would like to have golang-builder package your compiled Go application into a Docker image automatically then the final requirement is that your Dockerfile be placed at the root of your project directory structure. After compiling your Go application, golang-builder will execute a docker build with your Dockerfile.

The compiled binary will be placed in the root of your project directory so your Dockerfile can be written with the assumption that the application binary is in the same directory as the Dockerfile itself:

FROM scratch
EXPOSE 3000
COPY hello /
ENTRYPOINT ["/hello"]

In this case, the hello binary will be copied right to the root of the image and used as the entrypoint. Since we're using the empty scratch image as our base, there is no need to set-up any sort of directory structure inside the image.

If golang-builder does NOT see a Dockerfile in your project directory it will simply stop after compiling your application.

Usage…

Description from the Docker Hub listing.

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

portainer/golang-builder pulls on Docker Hub, last 90 days: 147,980 pulls as of Dec 6, 2026.portainer/golang-builderPulls on Docker Hub · Last 90 days147,980pulls147.5K147.6K147.7K147.8K147.9K148KSep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6pullsobservedarchived (Internet Archive)no observationsOct 16, 2026 – Dec 6, 2026 · 50 observations · Updated Dec…pluginstats.com
portainer/golang-builder pulls on Docker Hub, last 90 days: 147,980 pulls as of Dec 6, 2026.

7/30/90-day growth

portainer/golang-builder pulls growth on Docker Hub: +0.0% over 7 days, +0.2% over 30 days, 90-day growth unavailable.portainer/golang-builderPulls growth on Docker Hub147,980pulls now7-day growth+65 pulls+0.0%30-day growth+251 pulls+0.2%90-day growthinsufficient historyInsufficient historyGrowth vs. nearest observation to each baseline date · Updated Dec 6, 2026pluginstats.com
portainer/golang-builder pulls growth on Docker Hub: +0.0% over 7 days, +0.2% over 30 days, 90-day growth unavailable.

Ranking history

portainer/golang-builder Docker Hub ranking history: currently #370 (by pulls).portainer/golang-builderDocker Hub ranking · by pulls · Last 90 days#370current rank#350#355#360#365#370#375Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 16, 2026 – Dec 6, 2026 · 50 observations · Updated Dec 6, 2026pluginstats.com
portainer/golang-builder Docker Hub ranking history: currently #370 (by pulls).

Listing placement

All Docker Hub1,291 listings · 65 pages · page 19, #15 (overall #375)
All Docker Hub: every listing in pulls order

Listing placement

Languages & frameworks136 listings · 7 pages · page 4, #10 (overall #70)
Languages & frameworks: every listing in pulls order

Listing placement

Integration & delivery257 listings · 13 pages · page 6, #4 (overall #104)
Integration & delivery: every listing in pulls order

Listing placement

Security103 listings · 6 pages · page 3, #7 (overall #47)
Security: every listing in pulls order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Pulls on a linear scale. Placement is projected from pulls, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (50)
Recent pulls observations for portainer/golang-builder
Date (UTC)PullsChange vs. previous
147,980+7
147,973+3
147,970+20
147,950+14
147,936+9
147,927+4
147,923+8
147,915+21
147,894+5
147,889+8
147,881+20
147,861+12
147,849+2
147,847—

Similar Docker Hub Languages & frameworks plugins

All 20 portainer/golang-builder alternatives

Data source

Cumulative pull counts and stars come from the public Docker Hub API. Pulls count image downloads (including automated CI pulls), not installs or users.

Listing: https://hub.docker.com/r/portainer/golang-builder. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.