Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
master
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
executable file 20 lines (15 sloc) 412 Bytes
"use strict";
const throng = require("throng");
const thimble = require("./server");
const workers = process.env.WEB_CONCURRENCY || 1;
const start = function() {
const server = thimble.listen(process.env.PORT);
const shutdown = function() {
server.close(function() {
process.exit(0);
});
};
process.on("SIGINT", shutdown);
process.on("SIGTERM", shutdown);
};
throng(workers, start);