Moved runtime

This commit is contained in:
Romein van Buren 2023-02-24 09:45:56 +01:00
parent 2a724532c0
commit c27cf5c186
Signed by: romein
GPG Key ID: 0EFF8478ADDF6C49
2 changed files with 5 additions and 5 deletions

View File

@ -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);

View File

@ -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');