-
How to spin up an app, database and reverse proxy with docker compose from scratch
A compose.yaml with a healthcheck, conditional depends_on and a named volume brings up an app, Postgres and Nginx. Tested from scratch: database healthy in 27 s, app answering db=ok, proxy returning 200.
-
How to limit memory, logs and restarts of a container
Four limits cover most container problems in production: a memory cap, a pids cap, log rotation and a restart policy with a retry count. The compose.yaml below is the whole file, commented.
You reached the end. Every post is here.