Komut#cc-toolkit
0
Dockerfile
Geçerli proje için optimize edilmiş bir Docker dosyası oluşturun.
yazan kuscubasiece·8 Eylül 2026
Kaynak: rohitg00/awesome-claude-code-toolkit · Apache-2.0
Geçerli proje için optimize edilmiş bir Docker dosyası oluşturun.
Kaynak: rohitg00/awesome-claude-code-toolkit · Apache-2.0
mkdir -p .claude/commands && curl -sL https://www.antrophiclove.com/api/kaynak/dockerfile-cc-toolkit/raw -o .claude/commands/dockerfile-cc-toolkit.mdHedef dosya: .claude/commands/dockerfile-cc-toolkit.md
Generate an optimized Dockerfile for the current project.
node:22-alpine for runtime, node:22 for build if native modules are needed.python:3.12-slim for runtime, full image for build if compilation is needed.golang:1.23-alpine for build, gcr.io/distroless/static-debian12 for runtime.rust:1.82-slim for build, debian:bookworm-slim or scratch for runtime.# Stage 1: Build
FROM <build-image> AS builder
WORKDIR /app
COPY package*.json ./
RUN npm ci --production=false
COPY . .
RUN npm run build
# Stage 2: Runtime
FROM <runtime-image>
WORKDIR /app
COPY --from=builder /app/dist ./dist
COPY --from=builder /app/node_modules ./node_modules
EXPOSE 3000
USER node
CMD ["node", "dist/index.js"]
.dockerignore to exclude: .git, node_modules, dist, .env, tests, docs.NODE_ENV=production or equivalent.HEALTHCHECK CMD curl -f http://localhost:3000/health || exit 1.Create or update .dockerignore with sensible defaults for the project type.
.env files or secrets into the image.docker build -t app . && docker run -p 3000:3000 app.