Skip to content
cccskills
FreePublished on GitHub

docker-setup

Docker setup: Dockerfile best practices, multi-stage, compose, security, size optimization.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3 stars(GitHub 3 + cccskills 0)
Works withDocker

Run score Not tested

See how to install

Files included (5)

  • SKILL.md3.7 KB
  • references/anti-patterns.md560 B
  • references/checklists.md2.4 KB
  • references/compose-and-debugging.md2.8 KB
  • references/size-optimization.md322 B

SKILL.md (original)

Review the instructions the agent will receive before you install.

docker-setup — Docker & Compose Setup

Quick Start Checklist — Setup completo desde cero

  • .dockerignore creado antes de cualquier COPY (excluye .git, node_modules, .env, coverage, *.md)
  • Dockerfile multi-stage: stage builder separado del stage runtime
  • Base image con tag fijo, nunca :latest (ej: golang:1.22-alpine, node:20-alpine)
  • Dependencias copiadas e instaladas ANTES del código fuente (cache de layers)
  • Stage runtime usa imagen mínima: distroless (Go) o node:20-alpine (TS) o nginx:alpine (React)
  • USER nonroot o usuario no-root en stage runtime
  • HEALTHCHECK presente en cada servicio
  • Signal handler: tini/dumb-init en Node (Go nativo); CMD con exec form
  • docker-compose.yml con depends_on: condition: service_healthy
  • docker-compose.override.yml para dev-only (volúmenes, puertos) — no commiteado a prod
  • Secrets nunca en ENV ni en build args — solo via env vars en runtime o mounts
  • trivy image o docker scout en CI antes de push al registry
  • Runtime endurecido: read_only, cap_drop: [ALL], no-new-privileges, límites de memoria y PIDs (ver references/checklists.md)

Generate production-ready Dockerfiles and docker-compose for Go, TypeScript, and React stacks.

Principles

  1. Multi-stage builds — build != runtime. Final image is lean.
  2. Non-root user — never run as root in runtime stage
  3. Minimal base — distroless or alpine for runtime
  4. .dockerignore — exclude node_modules, .env, .git from build context
  5. Layer caching — copy dependency files before source code
  6. Health checks on all services
  7. Secrets via env vars / mounts — never in Dockerfile or image layers

Discovery questions

  1. Stack: Go / TS (Fastify/Express) / React+Vite / monorepo
  2. External services: Postgres / Redis / Kafka / others
  3. Target: dev local only / prod only / both
  4. Registry: GHCR / ECR / GCR
  5. Deploy target: K8s / ECS / Cloud Run

Base image selection

StackBuild stageRuntime stage
Gogolang:<version>-alpinegcr.io/distroless/static-debian12:nonroot
Node/TSnode:<version>-alpinenode:<version>-alpine + dumb-init/tini
React (static)node:<version>-alpinenginx:<version>-alpine

Dockerfile best practices checklist

→ Read references/checklists.md for Dockerfile best practices (10 items), security checklist (8 items), runtime hardening, and health check patterns

Compose decisions

ConcernDevProd
Build targetbuilder stage (for hot reload)runtime stage
VolumesSource mounted for live reloadNone (baked in)
Env vars.env file, LOG_LEVEL=debugInjected by orchestrator
PortsExposed to hostInternal only (behind LB)
Depends_oncondition: service_healthyManaged by orchestrator

Use docker-compose.override.yml for dev-only settings (auto-applied, not committed to prod).

→ Read references/compose-and-debugging.md for multiple compose files and config, profiles, watch mode, multi-platform builds, and a debugging table (exit codes, healthchecks, networking, volumes, disk)

Size optimization

→ Read references/size-optimization.md for image size reduction techniques

Anti-patterns

→ Read references/anti-patterns.md for 8 common Docker anti-patterns

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Plan, design, and implement A/B tests and experiments with statistical rigor. Covers hypothesis frameworks, sample sizing, metrics, and result analysis.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

Web/mobile accessibility decision guide: WCAG 2.2 AA, ARIA, keyboard nav, focus management, contrast, testing. Use for: a11y, accessibility, wcag, aria, screen reader, keyboard, contrast.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

Generate, iterate, and scale ad creative for paid advertising across Google, Meta, LinkedIn, and X. Covers platform specs, creative frameworks, and quality validation.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

Musica interactiva para juegos: layering vertical, re-secuenciacion horizontal, stingers, reglas de transicion con sync points, y mapeo de estados de gameplay a musica. Usar para: musica adaptativa, sistema de musica dinamica, transiciones musicales, combat music.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

Design multi-agent systems, create agent architectures, define communication patterns, and build autonomous agent workflows with structured evaluation frameworks.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

Inter-agent communication protocol for C-suite agent teams. Defines invocation syntax, loop prevention, isolation rules, response formats, and quality loops.

The English summary is being prepared. Showing the original description.

SebastianLuser/claude-code-arcane3Updated Oct 27, 2026

See all skills by SebastianLuser

Report a problem with this skill