mirror of
https://github.com/smartyellow/status.git
synced 2024-11-21 15:18:55 +01:00
Moved runtime
This commit is contained in:
parent
2a724532c0
commit
c27cf5c186
6
index.js
6
index.js
@ -327,7 +327,7 @@ module.exports = {
|
||||
return;
|
||||
}
|
||||
|
||||
const runtime = fork(__dirname + '/lib/runtime.js');
|
||||
const runtime = fork(__dirname + '/runtime.js');
|
||||
runtime.send({ command: 'testAll', services });
|
||||
|
||||
runtime.on('message', message => {
|
||||
@ -458,7 +458,7 @@ module.exports = {
|
||||
entity: [ 'smartyellow/webservice' ],
|
||||
purpose: 'Check whether services are up and send a notification if not.',
|
||||
handler: ({ item }) => {
|
||||
const runtime = fork(__dirname + '/lib/runtime.js');
|
||||
const runtime = fork(__dirname + '/runtime.js');
|
||||
runtime.send({ command: 'testOne', service: item });
|
||||
runtime.on('message', message => {
|
||||
if (message.error) {
|
||||
@ -535,7 +535,7 @@ module.exports = {
|
||||
requires: 'smartyellow/status/editServices',
|
||||
handler: async (req, res, user) => {
|
||||
const item = await server.storage({ user }).store('smartyellow/webservice').get(req.params[0]);
|
||||
const runtime = fork(__dirname + '/lib/runtime.js');
|
||||
const runtime = fork(__dirname + '/runtime.js');
|
||||
runtime.send({ command: 'testOne', service: item });
|
||||
runtime.on('message', async message => {
|
||||
res.json(message);
|
||||
|
@ -1,8 +1,8 @@
|
||||
'use strict';
|
||||
|
||||
const fetch = require('node-fetch');
|
||||
const { operators } = require('./operators');
|
||||
const { realValues } = require('./realvalues');
|
||||
const { operators } = require('./lib/operators');
|
||||
const { realValues } = require('./lib/realvalues');
|
||||
const http = require('http');
|
||||
const https = require('https');
|
||||
|
Loading…
Reference in New Issue
Block a user