Sample content — for template preview only, not a real project or article.
NOTE 001
Deploying applications with Docker
2026-02-10 · 5 min read · Deployment
This is a sample article used to preview the Field Notes template. It will be replaced with a real account of a production deployment.
The short version: a container that runs fine on a laptop can still fail in production, usually for reasons that have nothing to do with the application code.
Where it usually goes wrong
Three things tend to cause the most trouble:
- Environment variables that exist locally but were never set on the server
- File permissions that differ between the build image and the runtime image
- Health checks that pass immediately, before the app has actually finished starting
A minimal production-shaped setup
FROM node:20-slim AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
FROM node:20-slim
WORKDIR /app
COPY --from=build /app/.next ./.next
COPY --from=build /app/node_modules ./node_modules
CMD ["npm", "start"]
What I learned
Most Docker production issues aren't about Docker — they're about assumptions that only get tested once something else depends on the container actually staying up.