twelve-factor laravel
Empower your Laravel project as cloud native application
$: whoami
Dario TRANCHITELLA
(aka prometherion)
Former Software Engineer,
switched to the dark side of
DevOps
DevOps Engineer @ Kiratech
NOt many slides, just demos...
...hoping everything goes fine!
(meme courtesy of @liuggio)
I.
code
base
One codebase tracked in revision control, many deploys.
II.
DEPENDENCIES
Explicitly declare and isolate dependencies
(A twelve-factor app never relies on implicit existence of system-wide packages)
+
III.
CONFIG
The twelve-factor app stores config in environment variables.
Env vars are easy to change between deploys without changing any code.
IV.
BACKING SERVICES
Treat backing services as attached resources.
V.
Build,
release, run
A codebase is transformed into a (non-development) deploy through these three stages.
VI.
PROCESSES
Execute the app as one or more stateless processes.
+
VII.
Port binding
Export services via port binding.
VIII. Concurrency
Scale out via the process model.
IX. DISPOSABILITY
Maximize robustness with fast startup and graceful shutdown.
X.
DEV/PROD PARITY
Keep development, staging, and production as similar as possible.
XI.
LOGS
Treat logs as event streams.
+
XII.
Admin processes
Run admin/management tasks as one-off processes.
REFERENCES
- https://12factor.net
https://www.docker.com
https://laravel.com
https://github.com/prometherion/laravelday-2017
- https://twitter.com/tranchitellad
- http://www.kiratech.it
Q&A TIME!
LaravelDay 2017
By Dario Tranchitella
LaravelDay 2017
- 1,787