From 68e51a5a7f60e4fd1d83813dfd76082d21344c92 Mon Sep 17 00:00:00 2001 From: David Delassus Date: Wed, 3 Jul 2024 16:11:41 +0200 Subject: [PATCH 1/3] :sparkles: check if image digest is in output to determine success --- flows.json | 64 ++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 21 deletions(-) diff --git a/flows.json b/flows.json index 88c9f2d..63694fa 100644 --- a/flows.json +++ b/flows.json @@ -2749,7 +2749,7 @@ "y": 480, "wires": [ [ - "84d8b152e92556ef" + "5c79a22a8f9ad79f" ], [], [] @@ -2813,12 +2813,11 @@ "from": "", "to": "", "reg": false, - "x": 780, + "x": 800, "y": 480, "wires": [ [ - "b49c4832fc35827a", - "cedc032cfa072c59" + "b49c4832fc35827a" ] ] }, @@ -2855,7 +2854,7 @@ "property": "payload", "action": "", "pretty": false, - "x": 930, + "x": 1180, "y": 560, "wires": [ [ @@ -2875,7 +2874,7 @@ "winHide": false, "oldrc": false, "name": "images", - "x": 760, + "x": 1010, "y": 560, "wires": [ [ @@ -2904,7 +2903,7 @@ "from": "", "to": "", "reg": false, - "x": 1390, + "x": 1640, "y": 500, "wires": [ [ @@ -2966,7 +2965,7 @@ "from": "", "to": "", "reg": false, - "x": 1120, + "x": 1370, "y": 560, "wires": [ [ @@ -2991,7 +2990,7 @@ "authType": "", "senderr": false, "headers": [], - "x": 1330, + "x": 1580, "y": 600, "wires": [ [ @@ -3550,7 +3549,7 @@ "links": [ "36f439d2ba0ac71a" ], - "x": 1485, + "x": 1735, "y": 600, "wires": [] }, @@ -3568,7 +3567,7 @@ "type": "subflow:0455d311f0e53c09", "z": "3ea1a4b04d852f38", "name": "", - "x": 1350, + "x": 1900, "y": 560, "wires": [] }, @@ -3577,24 +3576,20 @@ "type": "switch", "z": "3ea1a4b04d852f38", "name": "", - "property": "$length(msg.payload)", - "propertyType": "jsonata", + "property": "payload", + "propertyType": "msg", "rules": [ { - "t": "lte", - "v": "512", - "vt": "num" + "t": "false" }, { - "t": "gt", - "v": "512", - "vt": "num" + "t": "true" } ], "checkall": "true", "repair": false, "outputs": 2, - "x": 1170, + "x": 1420, "y": 480, "wires": [ [ @@ -3624,7 +3619,7 @@ "from": "", "to": "", "reg": false, - "x": 1380, + "x": 1630, "y": 460, "wires": [ [ @@ -3641,6 +3636,33 @@ "y": 260, "wires": [] }, + { + "id": "5c79a22a8f9ad79f", + "type": "change", + "z": "3ea1a4b04d852f38", + "name": "find image digest in output", + "rules": [ + { + "t": "set", + "p": "payload", + "pt": "msg", + "to": "$count(\t $filter(\t $map(\t $split(payload, \"\\n\"),\t function($v) {\t $v != \"\" ? $eval($v)\t }\t ),\t function($v) {\t $match(\t $string($v.status),\t /^Digest:/\t )\t }\t )\t) > 0", + "tot": "jsonata" + } + ], + "action": "", + "property": "", + "from": "", + "to": "", + "reg": false, + "x": 1210, + "y": 480, + "wires": [ + [ + "84d8b152e92556ef" + ] + ] + }, { "id": "dcf35b57666a30f9", "type": "http in", From 7b2b9261e6cece0f5eabb3f8db2667e2c9ef1210 Mon Sep 17 00:00:00 2001 From: David Delassus Date: Wed, 3 Jul 2024 16:12:01 +0200 Subject: [PATCH 2/3] :bookmark: v0.29.2 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f459c46..4883edc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "netbox-docker-agent", - "version": "0.29.1", + "version": "0.29.2", "description": "Saashup agent for netbox manager", "main": "index.js", "scripts": { From 93801fde8702e83fcd26e934517cc2b4b45fbd02 Mon Sep 17 00:00:00 2001 From: David Delassus Date: Thu, 4 Jul 2024 12:52:24 +0200 Subject: [PATCH 3/3] :bug: reconnect JOURNAL node (was disconnected during debug) --- flows.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/flows.json b/flows.json index 63694fa..220f14f 100644 --- a/flows.json +++ b/flows.json @@ -2817,7 +2817,8 @@ "y": 480, "wires": [ [ - "b49c4832fc35827a" + "b49c4832fc35827a", + "cedc032cfa072c59" ] ] },