1 points · by durkes · 3y ago · 1 comment
I use this for running multiple processes on a single server for different domains or subdomains. It supports "hot reload" by just editing the map object in the configuration file, and works great behind something like Cloudflare.
const domainToPort = { 'localhost:3000': 3001, 'example.com': 3002, 'api.example.com': 3003, };