mirror of
https://github.com/xuthus83/pigallery2.git
synced 2025-01-14 14:43:17 +08:00
10 lines
214 B
TypeScript
10 lines
214 B
TypeScript
import * as cluster from "cluster";
|
|
|
|
if (cluster.isMaster) {
|
|
const Server = require("./server").Server;
|
|
new Server();
|
|
} else {
|
|
const Worker = require("./model/threading/Worker").Worker;
|
|
Worker.process();
|
|
}
|