Starts systemic systems
const Systemic = require('systemic');
const runner = require('systemic-service-runner');
const system = new Systemic().add('config', { foo: 1, bar: 2 }).add('app', require('./my-app')).dependsOn('config');
runner(system).start((err, components) => {
if (err) throw err;
console.log('Started');
});
- Attempts to shutdown gracefully on error, unhandled rejection, SIGINT and SIGTERM events
- Attempts a graceful restart when
process
emits asystemic_restart
event
runner(<system>, [<options>]).start(<cb>)
{
logger: console,
restart: {
window: '60s'
}
}