Background Services
Running an active Frappe environment requires the running of various systemlevel services and some Frappe processes.
The system level services, apart from your choice of database solutions andRedis will depend on your deployment architecture and strategy. As for theFrappe services, they are defined in theProcfile for development benchesand config/supervisor.conf for production benches.
System Processes
These processes are handled at a system level and may have configs setup viabench or some other Frappe deployment management tool.
- MariaDB/PostgreSQL (Database)
- Redis (Queues for background workers, and Caching)
- NGINX (Reverse Proxy for production deployment)
- Supervisor (Process Management for bench's non containerized production deployment)
Frappe Processes
These processes may be triggered manually or via a process manager. However,they are defined in Frappe's codebase and are managed by the same.
- WSGI Server
The WSGI server is responsible for responding to the HTTP requests to frappe. Ina development scenario,bench serve
orbench start
start the Werkzeug server.For production setups, Bench uses Gunicorn (automatically configured in supervisor).
- Redis Worker Processes
The worker processes execute background jobs in the Frappe system.
These processes are automatically started whenbench start
is run and for productionare configured in supervisor configuration.
- Scheduler Process
The Scheduler process schedules enqeueing of scheduled jobs in the Frappesystem. This process is automatically started whenbench start
is run and forproduction are configured in supervisor configuration.