Production Dockerfile
Generates a multi-stage, small-image Dockerfile for a given stack.
Multi-stage build, non-root user, .dockerignore, healthcheck, cache layers.
The prompt
Copy this into ChatGPT, Claude, Gemini or any assistant you already use β then paste your own stack description underneath it.
Generate a production-grade Dockerfile for the stack described. Output: **Dockerfile** (multi-stage) **.dockerignore** **1-line explanation per stage** Rules: - Use multi-stage builds. - Run as non-root. - Cache dependency install separately from source copy. - Pin base images by version, not :latest. - Add a HEALTHCHECK if appropriate for the runtime.
Example input
Node.js 20, Next.js 16, pnpm, runs on port 3000, deployed on Vercel-style platforms.
Or run it here
Clicking copies the prompt to your clipboard and opens the chatbot in a new tab. Gemini doesn't accept URL params β paste manually with Ctrl/Cmd+V.
Related prompts
Drafts an on-call runbook for a specific failure mode β detect, diagnose, mitigate, recover.
A complete CI pipeline YAML β lint, test, build, scan, deploy β for a Node/Python/Go service.
Writes a log query (Datadog / Splunk / Loki / CloudWatch) to surface what you need.
Plan for metrics, logs, traces, and alerts for a new service β what to instrument from day 1.
Decodes any cron schedule string into when it actually runs.
Skeleton for a Terraform module β main, variables, outputs, README.
Browse the full free AI prompt library or see more devops & sre prompts.