docker-deploy

docker-deploy is a skill for Claude Code, Codex from daibang123a/golang-agent-skills. It costs 87 tokens per session (1,669 once invoked), scanned A, original, MIT.

A deployment guide for packaging Go applications as Docker images and preparing related deployment files.

In plain words
What is it for?
Dockerizing Go web servers, gRPC services, command-line tools, and background workers, including Docker Compose and CI configuration.
Why use it?
It removes the need to design Docker build stages and supporting configuration from scratch for each Go project.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ./cmd/myservice.

Good fit Dockerizing Go web servers, gRPC services, command-line tools, and background workers, including Docker Compose and CI configuration.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/daibang123a/golang-agent-skills
agentmods
npx agentmods add skills/daibang123a/golang-agent-skills/docker-deploy

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for docker-deploy

README.md
[![agentmods](https://agentmods.dev/badge/skills/daibang123a/golang-agent-skills/docker-deploy/github.svg)](https://agentmods.dev/skills/daibang123a/golang-agent-skills/docker-deploy)
Your own site
<a href="https://agentmods.dev/skills/daibang123a/golang-agent-skills/docker-deploy"><img src="https://agentmods.dev/badge/skills/daibang123a/golang-agent-skills/docker-deploy/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for docker-deploy

Your own site · 80×15
<a href="https://agentmods.dev/skills/daibang123a/golang-agent-skills/docker-deploy"><img src="https://agentmods.dev/badge/skills/daibang123a/golang-agent-skills/docker-deploy.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 87 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,669 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00087 $0.01669
Opus 5 $0.00044 $0.00834
Sonnet 5 $0.00017 $0.00334
Haiku 4.5 $0.00009 $0.00167

Measured 10d ago against content hash 9302e94ca688, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

docker-deploy scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/generate-dockerfile.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/docker-deploy/SKILL.md · 222 lines

How it starts

The opening of the file, as written. The whole thing — 222 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Docker Deploy for Go

Build and deploy Go applications with production-optimized Docker images. Auto-detects project type and generates appropriate configurations.

How It Works

  1. Agent detects the project type by examining go.mod, main.go, and import paths
  2. Agent generates an optimized multi-stage Dockerfile
  3. Agent creates supporting files (docker-compose, .dockerignore, CI config)
  4. Agent reports image size and build metrics

Project Detection

Signal Project Type Base Image
net/http, chi, gin, echo Web server distroless/static
google.golang.org/grpc gRPC service distroless/static
cobra, urfave/cli CLI tool distroless/static
No network imports Worker/batch scratch

Dockerfile Templates

Web Service (Default)

# ---- Build Stage ----
FROM golang:1.22-alpine AS builder

# Install certificates and timezone data
RUN apk add --no-cache ca-certificates tzdata

WORKDIR /app

# Cache dependencies
COPY go.mod go.sum ./
RUN go mod download && go mod verify

# Build
COPY . .
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build \
    -ldflags="-s -w -X main.version=$(git describe --tags --always 2>/dev/null || echo dev)" \
    -trimpath \
    -o /bin/app \
    ./cmd/myservice

# ---- Runtime Stage ----
FROM gcr.io/distroless/static-debian12:nonroot

COPY --from=builder /usr/share/zoneinfo /usr/share/zoneinfo
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /bin/app /bin/app

EXPOSE 8080

USER nonroot:nonroot

ENTRYPOINT ["/bin/app"]

Scratch Image (Minimal)

FROM golang:1.22-alpine AS builder
RUN apk add --no-cache ca-certificates
WORKDIR /app
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 go build -ldflags="-s -w" -trimpath -o /bin/app ./cmd/myservice

FROM scratch
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /bin/app /bin/app
EXPOSE 8080
ENTRYPOINT ["/bin/app"]

Read the full file on GitHub · 222 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 222 lines · 87 tokens per session scan A 9302e94ca688

Subscribe to this mod's changes

docker-deploy is a skill published in the GitHub repository daibang123a/golang-agent-skills (2 stars, last pushed 6mo ago), licensed MIT. It adds 87 tokens to every session and 1,669 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

go-binary-size

Reduce the size of compiled Go binaries and container images: linker flags, inlining budget, CGO and build tags, embedded assets, dependency weight, and measuring what actually costs bytes. Use when a binary or image is too large, when shrinking a CLI for distribution, or when auditing what a dependency adds to the…

eduardo-sl/go-agent-skills · 138 tokens

go-containers

Go container optimization — scratch/distroless images, static binaries, CGO, ldflags, trimpath (846MB to 2.5MB). Use when working with Go containers or optimizing Go image sizes.

laurigates/claude-plugins · 47 tokens

go-deploy

Build and deploy Go applications — version detection, static binaries, CGO, workspaces, and Dockerfile patterns. Use when deploying a Go project, or when go.mod is detected.

nixopus/nixopus · 41 tokens

golang-k8s-agent

Use when building Go-based Kubernetes agents/controllers, reconcile loops, or cloud-native systems. Invoke for controller-runtime, CRDs, leader election, and Go concurrency.

Awish021/opencode · 39 tokens

docker-go

A command-line skill combining Docker and Go. Docker runs software in isolated containers, while Go is a programming language; the source does not describe the specific workflow this skill sets up.

openclaw-commons/openclaw-skill-commons · 0 tokens

ast-grep

Guide for writing ast-grep rules to perform structural code search and analysis. Use when users need to search codebases using Abstract Syntax Tree (AST) patterns, find specific code structures, or perform complex code queries that go beyond simple text search. This skill should be used when users ask to search for…

JanDeDobbeleer/oh-my-posh · 80 tokens