Run a microservices site
Start an MDK site from the PM2 or Docker microservices example.
This thin page directs you to the correct location for the prerequisites, config fields, run command, smoke test, and troubleshooting.
Overview
Use the microservices site example when you want the Gateway and Workers to run as separate OS processes or containers.
This page is the task guide for the microservices topology. The deployment topologies concept explains when to choose microservices instead of single-process.
Use this topology when
- You need supervisor-managed restarts and logs
- You want to restart or scale one service without restarting the others
- You want a production-like layout for Gateway and Workers
Run the example
Follow the microservices site example, whose interactive CLI starts Kernel, Gateway, and each Worker as its own OS process, with per-process logs and status:
- Start with the prerequisites
- Bring up every component as a separate process with the
cli.jsprocess manager
Next steps
- Compare the supported shapes: Deployment topologies
- Run the simpler local topology — Run a single-process site
- Register a single miner before building a site config — Run a miner Worker