Author : Adam Wiggins
- One APP, one repo.
- One repo, many deploys.
- A dependency list with code.
- Good to new developers.
- Config means the information about environment.
- Do not put config files in repo.
- Do not use constant to save config information.
- Do not manage config with group.
- Use enviroment variables.
PS : How to manage these config information under version control system?
IV. Backing Services
- Regard every service, no matter which kind it is, as a resource.
- Treat local services and third party services in the same way.
V. Build, Release, Run
- Three stags for a new version APP’s publishment :
- Build - Check and compile the code into an executable file.
- Release - Combinate the executable file and config.
- Run - Deploy the software package to the production environment and run it.
- Processes must be stateless.
VII . Port Binding
- Communicate with other services only by port binding, do not rely on them at all.
- Recieve cues from operating system’s manager instead of PID files.
- A good process can be shutdown gracefully after receiving the signal.
- To face the unexpected death, queueing backend is recommended.
X. Dev/prod parity
- Minimize the gap between development and production.
- Use the same tools in different environments, including the
- Deploy your code as soon as possible.
- Processes should write the log information to
- Collect logs and
XII. Admin processes
- Use REPL the run
one-offprocesses to do some administrative and maintainance tasks.