crule
parent
97e5c31e5d
commit
281f880155
|
@ -0,0 +1 @@
|
|||
node_modules/
|
|
@ -0,0 +1,30 @@
|
|||
require('./init')
|
||||
var http = require('http');
|
||||
var express = require("express");
|
||||
var RED = require("node-red");
|
||||
|
||||
const { redSettings } = require('./settings')
|
||||
|
||||
var app = express();
|
||||
|
||||
app.use("/static",express.static("public"));
|
||||
|
||||
var server = http.createServer(app);
|
||||
|
||||
RED.init(server,redSettings);
|
||||
|
||||
if (redSettings.httpAdminRoot !== false) {
|
||||
app.use(redSettings.httpAdminRoot,RED.httpAdmin);
|
||||
}
|
||||
|
||||
// if (redSettings.httpNodeRoot !== false && redSettings.httpNodeAuth) {
|
||||
// app.use(redSettings.httpNodeRoot,basicAuthMiddleware(redSettings.httpNodeAuth.user,redSettings.httpNodeAuth.pass));
|
||||
// }
|
||||
// if (redSettings.httpNodeRoot !== false && redSettings.nodeAuth) {
|
||||
// app.use(redSettings.httpNodeRoot,tokensAuthMiddleware(redSettings.nodeAuth.tokens));
|
||||
// }
|
||||
if(redSettings.httpNodeRoot !== false){
|
||||
app.use(redSettings.httpNodeRoot,RED.httpNode);
|
||||
}
|
||||
server.listen(1880);
|
||||
RED.start();
|
|
@ -0,0 +1,430 @@
|
|||
{
|
||||
"node-red": {
|
||||
"name": "node-red",
|
||||
"version": "3.1.0-git",
|
||||
"local": false,
|
||||
"user": false,
|
||||
"nodes": {
|
||||
"junction": {
|
||||
"name": "junction",
|
||||
"types": [
|
||||
"junction"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/05-junction.js"
|
||||
},
|
||||
"inject": {
|
||||
"name": "inject",
|
||||
"types": [
|
||||
"inject"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/20-inject.js"
|
||||
},
|
||||
"debug": {
|
||||
"name": "debug",
|
||||
"types": [
|
||||
"debug"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/21-debug.js"
|
||||
},
|
||||
"complete": {
|
||||
"name": "complete",
|
||||
"types": [
|
||||
"complete"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/24-complete.js"
|
||||
},
|
||||
"catch": {
|
||||
"name": "catch",
|
||||
"types": [
|
||||
"catch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/25-catch.js"
|
||||
},
|
||||
"status": {
|
||||
"name": "status",
|
||||
"types": [
|
||||
"status"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/25-status.js"
|
||||
},
|
||||
"link": {
|
||||
"name": "link",
|
||||
"types": [
|
||||
"link in",
|
||||
"link out",
|
||||
"link call"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/60-link.js"
|
||||
},
|
||||
"comment": {
|
||||
"name": "comment",
|
||||
"types": [
|
||||
"comment"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/90-comment.js"
|
||||
},
|
||||
"global-config": {
|
||||
"name": "global-config",
|
||||
"types": [
|
||||
"global-config"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/91-global-config.js"
|
||||
},
|
||||
"unknown": {
|
||||
"name": "unknown",
|
||||
"types": [
|
||||
"unknown"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/98-unknown.js"
|
||||
},
|
||||
"function": {
|
||||
"name": "function",
|
||||
"types": [
|
||||
"function"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/10-function.js"
|
||||
},
|
||||
"switch": {
|
||||
"name": "switch",
|
||||
"types": [
|
||||
"switch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/10-switch.js"
|
||||
},
|
||||
"change": {
|
||||
"name": "change",
|
||||
"types": [
|
||||
"change"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/15-change.js"
|
||||
},
|
||||
"range": {
|
||||
"name": "range",
|
||||
"types": [
|
||||
"range"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/16-range.js"
|
||||
},
|
||||
"template": {
|
||||
"name": "template",
|
||||
"types": [
|
||||
"template"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/80-template.js"
|
||||
},
|
||||
"delay": {
|
||||
"name": "delay",
|
||||
"types": [
|
||||
"delay"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/89-delay.js"
|
||||
},
|
||||
"trigger": {
|
||||
"name": "trigger",
|
||||
"types": [
|
||||
"trigger"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/89-trigger.js"
|
||||
},
|
||||
"exec": {
|
||||
"name": "exec",
|
||||
"types": [
|
||||
"exec"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/90-exec.js"
|
||||
},
|
||||
"rbe": {
|
||||
"name": "rbe",
|
||||
"types": [
|
||||
"rbe"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/rbe.js"
|
||||
},
|
||||
"tls": {
|
||||
"name": "tls",
|
||||
"types": [
|
||||
"tls-config"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/05-tls.js"
|
||||
},
|
||||
"httpproxy": {
|
||||
"name": "httpproxy",
|
||||
"types": [
|
||||
"http proxy"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/06-httpproxy.js"
|
||||
},
|
||||
"mqtt": {
|
||||
"name": "mqtt",
|
||||
"types": [
|
||||
"mqtt in",
|
||||
"mqtt out",
|
||||
"mqtt-broker"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/10-mqtt.js"
|
||||
},
|
||||
"httpin": {
|
||||
"name": "httpin",
|
||||
"types": [
|
||||
"http in",
|
||||
"http response"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/21-httpin.js"
|
||||
},
|
||||
"httprequest": {
|
||||
"name": "httprequest",
|
||||
"types": [
|
||||
"http request"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/21-httprequest.js"
|
||||
},
|
||||
"websocket": {
|
||||
"name": "websocket",
|
||||
"types": [
|
||||
"websocket in",
|
||||
"websocket out",
|
||||
"websocket-listener",
|
||||
"websocket-client"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/22-websocket.js"
|
||||
},
|
||||
"tcpin": {
|
||||
"name": "tcpin",
|
||||
"types": [
|
||||
"tcp in",
|
||||
"tcp out",
|
||||
"tcp request"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/31-tcpin.js"
|
||||
},
|
||||
"udp": {
|
||||
"name": "udp",
|
||||
"types": [
|
||||
"udp in",
|
||||
"udp out"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/32-udp.js"
|
||||
},
|
||||
"CSV": {
|
||||
"name": "CSV",
|
||||
"types": [
|
||||
"csv"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-CSV.js"
|
||||
},
|
||||
"HTML": {
|
||||
"name": "HTML",
|
||||
"types": [
|
||||
"html"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-HTML.js"
|
||||
},
|
||||
"JSON": {
|
||||
"name": "JSON",
|
||||
"types": [
|
||||
"json"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-JSON.js"
|
||||
},
|
||||
"XML": {
|
||||
"name": "XML",
|
||||
"types": [
|
||||
"xml"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-XML.js"
|
||||
},
|
||||
"YAML": {
|
||||
"name": "YAML",
|
||||
"types": [
|
||||
"yaml"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-YAML.js"
|
||||
},
|
||||
"split": {
|
||||
"name": "split",
|
||||
"types": [
|
||||
"split",
|
||||
"join"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/17-split.js"
|
||||
},
|
||||
"sort": {
|
||||
"name": "sort",
|
||||
"types": [
|
||||
"sort"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/18-sort.js"
|
||||
},
|
||||
"batch": {
|
||||
"name": "batch",
|
||||
"types": [
|
||||
"batch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/19-batch.js"
|
||||
},
|
||||
"file": {
|
||||
"name": "file",
|
||||
"types": [
|
||||
"file",
|
||||
"file in"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/storage/10-file.js"
|
||||
},
|
||||
"watch": {
|
||||
"name": "watch",
|
||||
"types": [
|
||||
"watch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/storage/23-watch.js"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,428 @@
|
|||
{
|
||||
"node-red": {
|
||||
"name": "node-red",
|
||||
"version": "3.1.0-git",
|
||||
"local": false,
|
||||
"user": false,
|
||||
"nodes": {
|
||||
"junction": {
|
||||
"name": "junction",
|
||||
"types": [],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/05-junction.js"
|
||||
},
|
||||
"inject": {
|
||||
"name": "inject",
|
||||
"types": [
|
||||
"inject"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/20-inject.js"
|
||||
},
|
||||
"debug": {
|
||||
"name": "debug",
|
||||
"types": [
|
||||
"debug"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/21-debug.js"
|
||||
},
|
||||
"complete": {
|
||||
"name": "complete",
|
||||
"types": [
|
||||
"complete"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/24-complete.js"
|
||||
},
|
||||
"catch": {
|
||||
"name": "catch",
|
||||
"types": [
|
||||
"catch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/25-catch.js"
|
||||
},
|
||||
"status": {
|
||||
"name": "status",
|
||||
"types": [
|
||||
"status"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/25-status.js"
|
||||
},
|
||||
"link": {
|
||||
"name": "link",
|
||||
"types": [
|
||||
"link in",
|
||||
"link out",
|
||||
"link call"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/60-link.js"
|
||||
},
|
||||
"comment": {
|
||||
"name": "comment",
|
||||
"types": [
|
||||
"comment"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/90-comment.js"
|
||||
},
|
||||
"global-config": {
|
||||
"name": "global-config",
|
||||
"types": [
|
||||
"global-config"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/91-global-config.js"
|
||||
},
|
||||
"unknown": {
|
||||
"name": "unknown",
|
||||
"types": [
|
||||
"unknown"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/common/98-unknown.js"
|
||||
},
|
||||
"function": {
|
||||
"name": "function",
|
||||
"types": [
|
||||
"function"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/10-function.js"
|
||||
},
|
||||
"switch": {
|
||||
"name": "switch",
|
||||
"types": [
|
||||
"switch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/10-switch.js"
|
||||
},
|
||||
"change": {
|
||||
"name": "change",
|
||||
"types": [
|
||||
"change"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/15-change.js"
|
||||
},
|
||||
"range": {
|
||||
"name": "range",
|
||||
"types": [
|
||||
"range"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/16-range.js"
|
||||
},
|
||||
"template": {
|
||||
"name": "template",
|
||||
"types": [
|
||||
"template"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/80-template.js"
|
||||
},
|
||||
"delay": {
|
||||
"name": "delay",
|
||||
"types": [
|
||||
"delay"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/89-delay.js"
|
||||
},
|
||||
"trigger": {
|
||||
"name": "trigger",
|
||||
"types": [
|
||||
"trigger"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/89-trigger.js"
|
||||
},
|
||||
"exec": {
|
||||
"name": "exec",
|
||||
"types": [
|
||||
"exec"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/90-exec.js"
|
||||
},
|
||||
"rbe": {
|
||||
"name": "rbe",
|
||||
"types": [
|
||||
"rbe"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/function/rbe.js"
|
||||
},
|
||||
"tls": {
|
||||
"name": "tls",
|
||||
"types": [
|
||||
"tls-config"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/05-tls.js"
|
||||
},
|
||||
"httpproxy": {
|
||||
"name": "httpproxy",
|
||||
"types": [
|
||||
"http proxy"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/06-httpproxy.js"
|
||||
},
|
||||
"mqtt": {
|
||||
"name": "mqtt",
|
||||
"types": [
|
||||
"mqtt in",
|
||||
"mqtt out",
|
||||
"mqtt-broker"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/10-mqtt.js"
|
||||
},
|
||||
"httpin": {
|
||||
"name": "httpin",
|
||||
"types": [
|
||||
"http in",
|
||||
"http response"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/21-httpin.js"
|
||||
},
|
||||
"httprequest": {
|
||||
"name": "httprequest",
|
||||
"types": [
|
||||
"http request"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/21-httprequest.js"
|
||||
},
|
||||
"websocket": {
|
||||
"name": "websocket",
|
||||
"types": [
|
||||
"websocket in",
|
||||
"websocket out",
|
||||
"websocket-listener",
|
||||
"websocket-client"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/22-websocket.js"
|
||||
},
|
||||
"tcpin": {
|
||||
"name": "tcpin",
|
||||
"types": [
|
||||
"tcp in",
|
||||
"tcp out",
|
||||
"tcp request"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/31-tcpin.js"
|
||||
},
|
||||
"udp": {
|
||||
"name": "udp",
|
||||
"types": [
|
||||
"udp in",
|
||||
"udp out"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/network/32-udp.js"
|
||||
},
|
||||
"CSV": {
|
||||
"name": "CSV",
|
||||
"types": [
|
||||
"csv"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-CSV.js"
|
||||
},
|
||||
"HTML": {
|
||||
"name": "HTML",
|
||||
"types": [
|
||||
"html"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-HTML.js"
|
||||
},
|
||||
"JSON": {
|
||||
"name": "JSON",
|
||||
"types": [
|
||||
"json"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-JSON.js"
|
||||
},
|
||||
"XML": {
|
||||
"name": "XML",
|
||||
"types": [
|
||||
"xml"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-XML.js"
|
||||
},
|
||||
"YAML": {
|
||||
"name": "YAML",
|
||||
"types": [
|
||||
"yaml"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/parsers/70-YAML.js"
|
||||
},
|
||||
"split": {
|
||||
"name": "split",
|
||||
"types": [
|
||||
"split",
|
||||
"join"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/17-split.js"
|
||||
},
|
||||
"sort": {
|
||||
"name": "sort",
|
||||
"types": [
|
||||
"sort"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/18-sort.js"
|
||||
},
|
||||
"batch": {
|
||||
"name": "batch",
|
||||
"types": [
|
||||
"batch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/sequence/19-batch.js"
|
||||
},
|
||||
"file": {
|
||||
"name": "file",
|
||||
"types": [
|
||||
"file",
|
||||
"file in"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/storage/10-file.js"
|
||||
},
|
||||
"watch": {
|
||||
"name": "watch",
|
||||
"types": [
|
||||
"watch"
|
||||
],
|
||||
"enabled": true,
|
||||
"local": false,
|
||||
"user": false,
|
||||
"module": "node-red",
|
||||
"file": "/cc/shiki/crule/node_modules/@node-red/nodes/core/storage/23-watch.js"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"_credentialSecret": "63cfd09661840e562dff716253ab4783ce9ecc91426863a3264cac567bb098a5"
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
"_": {
|
||||
"editor": {
|
||||
"view": {
|
||||
"view-store-zoom": false,
|
||||
"view-store-position": false,
|
||||
"view-show-grid": true,
|
||||
"view-snap-grid": true,
|
||||
"view-grid-size": 20,
|
||||
"view-node-status": true,
|
||||
"view-node-show-label": true,
|
||||
"view-show-tips": true,
|
||||
"view-show-welcome-tours": true
|
||||
},
|
||||
"tours": {
|
||||
"welcome": "3.1.0-git"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"_": {
|
||||
"editor": {
|
||||
"view": {
|
||||
"view-store-zoom": false,
|
||||
"view-store-position": false,
|
||||
"view-show-grid": true,
|
||||
"view-snap-grid": true,
|
||||
"view-grid-size": 20,
|
||||
"view-node-status": true,
|
||||
"view-node-show-label": true,
|
||||
"view-show-tips": true,
|
||||
"view-show-welcome-tours": true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"name": "node-red-project",
|
||||
"description": "A Node-RED Project",
|
||||
"version": "0.0.1",
|
||||
"private": true
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
const path = require('path')
|
||||
|
||||
process.env.rootPath=path.dirname(__dirname)
|
||||
|
||||
module.exports=function(app){
|
||||
|
||||
}
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
"name": "crule",
|
||||
"version": "1.0.0",
|
||||
"description": "node-red二开",
|
||||
"main": "crule.js",
|
||||
"scripts": {
|
||||
"dev": "node crule.js"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "http://10.10.10.1:8003/gitcc/crule.git"
|
||||
},
|
||||
"author": "cc",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"express": "^4.18.2",
|
||||
"node-red": "^3.1.0"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
:root{
|
||||
--red-ui-header-background: #304156;
|
||||
}
|
||||
#red-ui-header span.red-ui-header-logo img {
|
||||
height: 30px !important;
|
||||
}
|
||||
.my-logout{
|
||||
line-height: 40px;
|
||||
float: right;
|
||||
background: #000;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.my-logout a{
|
||||
vertical-align:middle;
|
||||
font-size: 16px;
|
||||
color: #ccc !important;
|
||||
padding: 0px 10px;
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
@font-face {font-family: "iconfont";
|
||||
src: url('iconfont.eot?t=1587777259490'); /* IE9 */
|
||||
src: url('iconfont.eot?t=1587777259490#iefix') format('embedded-opentype'), /* IE6-IE8 */
|
||||
url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAAAPwAAsAAAAACCQAAAOkAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHEIGVgCDBgqEBINBATYCJAMMCwgABCAFhG0HPRsOBxHVm0fJfibYNg+ys/YN8Wx8EtMwaU3wgN9ZL8m0m04X5sHEl1gcqL8GQAECb841+VejItRIzj559IW0vJSe/rh32hSfDyiXP1aLxt4cdQHGAQU01qa2aIEk6C2yO4O8qPUQgEks2Ygq1eo0QWNgdROA6NOze0d0To3RkivQCKw1Yw3EAixoOVNeB+aH3xefKCQ0SCwKq2+DblW7UOGtepuoJnjQxmdBTGcEhEmggGzAANGu1twCFYezUZiawmhPtWIgkFP5PJ4Q12VW+w8PJAKEFSvbG4B0EpHwVrl4qkzE5FUTD9fZCmhgC+CWNcFYr1RYkrwjI2z+QaGjXa5ix66GNjvvFhNdzRwONjrLsuRykSOOJisizr6Y+6r86kET3c2dThyOJi5XS+eYsMO30o6709KSblS9VD8hZauz6NYbBUsdo03h6r1ME8wjt6Pl2jtF/Y7fi1Pr7vZzCy9oivfQFTuSfbftilSrd6f5bd0Z0eHImegJe1NYuXP27iixfb9Yd64JE+0mE5bMWiYE6ECxev/svRErdpTuUCa2VoviW1I3/6dGv+xBJSeP2TNG2vX2TNZZg9rW+r85dUtTQWyt1f9aiehgp7DVv8mfeneY20GSeh3n9hYt+65uZDQ0/D3Pn/gjF6U1HvnvV9UqobXP6qQDB5L03lpVwpr++jeycW1dChf89xlpH7xx+XBJEILEjUf6HDjps9PceaHbgVPeYUGjkba200Z3FBShCG058kM7X8vNAd0afPbaSd/4xdq7erxHhlax1ZYr01bKGvbKIZZnvjMiUaqCPu1/WjcPrRNo+17ku82/Nh0A8FQXVQUUpdaqCX/2Nxz8X/pNe78yf7TdAODhlf2fsNPDAJYJGglg4j8SwBJDpyyNMlTcxc2YojWWt4RiVFTy9/IBAnk63BoCqVGgRQKDxIsYUGiS2QY/GyzYKQJWNOXBJIvqk+0EMQiFMGxAJlMRCPzZDxJfzoPCnxtsg/8ELITyBaz4CwUmzUTQnHZShezYsSLvqED8wUnataPrLMq9oXlHXrNUKHhhbc4HyzgXY1fcsU4xoH3M2rsGXSnBBW2GMRLkSh5lH23veZsmXXelUVIaGJUr8o4KxB+cpF37lTsrff6G5h15bSmqSb+wNlc7LOMMYF8VO6joVi5pH7P2rkFXSnBBRox2mCDXt/Io+2gHBPM2kXIaqhiXV6X3WwWYWEcpIYUSBnpow7rzhIfMW/tSVcMA') format('woff2'),
|
||||
url('iconfont.woff?t=1587777259490') format('woff'),
|
||||
url('iconfont.ttf?t=1587777259490') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
|
||||
url('iconfont.svg?t=1587777259490#iconfont') format('svg'); /* iOS 4.1- */
|
||||
}
|
||||
|
||||
.iconfont {
|
||||
font-family: "iconfont" !important;
|
||||
font-size: 16px;
|
||||
font-style: normal;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.icon-username:before {
|
||||
content: "\e622";
|
||||
}
|
||||
|
||||
.icon-password:before {
|
||||
content: "\e603";
|
||||
}
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
body{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.content{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-content: space-around;
|
||||
align-items: center;
|
||||
width: 500px;
|
||||
height: 320px;
|
||||
border: 1px solid rgba(0,0,0,0.2);
|
||||
border-radius: 5px;
|
||||
box-shadow: 5px 5px 10px #333;
|
||||
background: #fefefe;
|
||||
}
|
||||
.content > *{
|
||||
margin: 5px 0;
|
||||
}
|
||||
.logo{
|
||||
width: 200px;
|
||||
height:50px;
|
||||
}
|
||||
.v5w{
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.login-form{
|
||||
width: 250px;
|
||||
}
|
||||
.login-form > *{
|
||||
margin: 8px 0px;
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
body,html{
|
||||
height: 100%;
|
||||
background: #337ab7;
|
||||
}
|
||||
|
||||
|
||||
.btn-sm{
|
||||
cursor: pointer;
|
||||
}
|
Binary file not shown.
After Width: | Height: | Size: 6.3 KiB |
Binary file not shown.
After Width: | Height: | Size: 6.1 KiB |
Binary file not shown.
After Width: | Height: | Size: 533 B |
|
@ -0,0 +1,5 @@
|
|||
const redSettings = require('./settings')
|
||||
|
||||
module.exports = {
|
||||
redSettings
|
||||
}
|
|
@ -0,0 +1,116 @@
|
|||
// const redFunction = require('../function_global_context')
|
||||
const userDir = require('path').join(process.env.rootPath, 'crule_data')
|
||||
const path = require('path')
|
||||
|
||||
// const { JSDOM } = require( "jsdom" );
|
||||
// const { window } = new JSDOM( "" );
|
||||
// const $ = require( "jquery" )( window );
|
||||
|
||||
// Create the settings object - see default settings.js file for other options
|
||||
module.exports = {
|
||||
httpAdminRoot: "/red",
|
||||
httpNodeRoot: "/api",
|
||||
userDir: userDir,
|
||||
ui: { path: '/ui' },
|
||||
// functionGlobalContext: redFunction, // enables global context
|
||||
flowFile:path.join(userDir,"crule.json"),
|
||||
// adminAuth: {
|
||||
// tokensOptions: {
|
||||
// name: "bihua",
|
||||
// title:"规则引擎认证不通过!",
|
||||
// subTitle:"请通过碧华后台管理系统-规则编排访问规则引擎!",
|
||||
// label: '碧华后台管理系统',
|
||||
// icon:"fa-arrow-right",
|
||||
// url:"http://bihua.vip.cpolar.top/login"
|
||||
// },
|
||||
// tokens: function(token) {
|
||||
// return new Promise(function(resolve, reject) {
|
||||
// // Do whatever work is needed to check token is valid
|
||||
// $.ajax({
|
||||
// headers: {
|
||||
// "authorization":"Bearer "+token
|
||||
// },
|
||||
// cache: false,
|
||||
// url: "http://bihua.vip.cpolar.top/prod-api/iot/rulearrangement/tokens",
|
||||
// type: "GET",
|
||||
// success: function(data) {
|
||||
// console.info("tokens-api:"+ data.code);
|
||||
// if (data.code == 200) {
|
||||
// console.info("tokens-api-success:"+ token);
|
||||
// // Resolve with the user object. It must contain
|
||||
// // properties 'username' and 'permissions'
|
||||
// var user = { username: 'admin', permissions: '*' };
|
||||
// resolve(user);
|
||||
// } else {
|
||||
// console.info("tokens-api-fail:"+ token);
|
||||
// // Resolve with null as this user does not exist
|
||||
// resolve(null);
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// });
|
||||
// }
|
||||
// },
|
||||
// //httpNodeAuth: {user:"user",pass:"$2a$08$1YPhh6WQdiqJo6gXCWB8IOUl5U7ajIIYMkIGBSQSaUQZG3MKUu2Ze"},
|
||||
// nodeAuth: {
|
||||
// tokens: function(token) {
|
||||
// console.info("node-token:"+token);
|
||||
// return new Promise(function(resolve, reject) {
|
||||
// // Do whatever work is needed to check token is valid
|
||||
// if (true) {
|
||||
// // Resolve with the user object. It must contain
|
||||
// // properties 'username' and 'permissions'
|
||||
// var user = { username: 'admin', permissions: '*' };
|
||||
// resolve(user);
|
||||
// } else {
|
||||
// // Resolve with null as this user does not exist
|
||||
// resolve(null);
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
// },
|
||||
// httpNodeCors: {
|
||||
// origin: "*",
|
||||
// methods: "GET,PUT,POST,DELETE"
|
||||
// },
|
||||
editorTheme: {
|
||||
page: {
|
||||
title: 'crule',
|
||||
css: path.join(process.env.rootPath,'public','css','crule.css')
|
||||
},
|
||||
header: {
|
||||
title: "规则引擎",
|
||||
image: path.join(process.env.rootPath,'public','images','logo.png'),
|
||||
},
|
||||
deployButton: {
|
||||
type:"simple",
|
||||
label:"保存",
|
||||
// deployNotice: function(token, flowId) {
|
||||
// //console.info("deployNotice-token:"+token);
|
||||
// //console.info("deployNotice-flowId:"+flowId);
|
||||
// $.ajax({
|
||||
// headers: {
|
||||
// "authorization":"Bearer "+token
|
||||
// },
|
||||
// cache: false,
|
||||
// url: "http://bihua.vip.cpolar.top/prod-api/iot/rulearrangement/updateRuleContent/"+flowId,
|
||||
// type: "GET",
|
||||
// success: function(data) {
|
||||
// console.info("deployNotice-success-data:"+ JSON.stringify(data));
|
||||
// }
|
||||
// });
|
||||
// },
|
||||
icon: path.join(process.env.rootPath,'public','images','save.png') // or null to remove image
|
||||
},
|
||||
menu: { // Hide unwanted menu items by id. see packages/node_modules/@node-red/editor-client/src/js/red.js:loadEditor for complete list
|
||||
"menu-item-import-library": false,
|
||||
"menu-item-export-library": false,
|
||||
"menu-item-keyboard-shortcuts": false,
|
||||
"menu-item-help": {
|
||||
label: "Alternative Help Link Text",
|
||||
url: "http://example.com"
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue