180
twelve-factor app
Config in the environment. State in a backing service. Processes are disposable. Logs go to stdout.
What is twelve-factor app?
Twelve-factor is a checklist for apps that run on a platform: one codebase, explicit dependencies, config in the environment, backing services as attached resources, stateless processes, port binding, concurrency by process, disposability, dev/prod parity, logs as event streams, admin tasks as one-off processes.
Why does twelve-factor app matter when vibe coding?
Models read a config file from disk and write logs into the container. The platform cannot configure or collect them. Name the factors you are about to break.
How do you do twelve-factor app?
Env vars for config. Stdout for logs. No local disk for state. The same artifact in every environment. Admin jobs are separate processes, not SSH.
How do you ask a model for twelve-factor app?
Follow twelve-factor for (service): config from the environment, logs to stdout, no state on local disk, same image in every environment. Do not read a config file baked into the image.
What goes wrong with twelve-factor app?
Citing twelve-factor while building a pet server that only starts if a volume is hand-made. Disposability is the test. Kill it and start another.