/
githubmirror
/
pm2
Обзор
Документация
Войти
/
githubmirror
/
pm2
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
test/fixtures/start-app/http.js
20 строк
468 B
Alexandre Strzelewicz
feature: allow to start raw command via `pm2 start "my command with params"` + alias script in ecosystem file with cmd & command
27 май 2018, 17:07
27 май 2018, 17:07
af60e99
Код
Авторство
О чём код?
var http = require('http'); var app = http.createServer(function(req, res) { res.writeHead(200); res.end('hey'); }) var listener = app.listen(0, function() { console.log('Listening on port ' + listener.address().port); }); process.on('message', function(msg) { if (msg == 'shutdown') { console.log('Closing all connections...'); setTimeout(function() { console.log('Finished closing connections'); process.exit(0); }, 100); } });