Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if (services[service]) {
if (services[service].running) {
zen.send_admin_message(service + ' is already running');
} else {
zen.send_admin_message('starting ' + service);
services[service].start();
}
} else {
zen.send_admin_message('starting ' + service);
child = forever.start([language_map[service.split('.')[1]], service], {
max: 10000,
silent: false
});
forever.startServer(child);
services[service] = child;
forever.cli.list();
}
}