Migrate to new Gitea instance (gitea.wbd-rd.nl)

- Update all submodule URLs from gitea.centraal.wbd-rd.nl to gitea.wbd-rd.nl
- Add settler as proper submodule in .gitmodules
- Add agent skills, function anchors, decisions, and improvements
- Add Docker configuration and scripts
- Add manuals and third_party docs
- Update .gitignore with secrets and build artifacts
- Remove stale .tgz build artifact

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
znetsixe
2026-03-04 21:07:04 +01:00
parent fbd9e6ec11
commit 6a6c04d34b
169 changed files with 21332 additions and 1512 deletions

92
scripts/validate-nodes.sh Normal file
View File

@@ -0,0 +1,92 @@
#!/bin/sh
# =============================================================
# EVOLV Node Loading Validator
# Checks that all expected EVOLV nodes are loaded in Node-RED
# =============================================================
set -e
NODERED_URL="${NODERED_URL:-http://localhost:1880}"
TIMEOUT="${TIMEOUT:-30}"
# Colors
RED='\033[0;31m'
GREEN='\033[0;32m'
YELLOW='\033[0;33m'
NC='\033[0m'
# Expected EVOLV nodes (from package.json node-red.nodes)
EXPECTED_NODES="dashboardapi machineGroupControl measurement monster reactor rotatingMachine valve valveGroupControl pumpingstation settler"
echo "=============================================="
echo " EVOLV Node Validation"
echo " URL: $NODERED_URL"
echo "=============================================="
echo ""
# ---------------------------------------------------------
# Wait for Node-RED readiness
# ---------------------------------------------------------
printf "Waiting for Node-RED to be ready"
elapsed=0
while [ $elapsed -lt $TIMEOUT ]; do
if curl -sf "$NODERED_URL/nodes" > /dev/null 2>&1; then
printf " ${GREEN}ready${NC} (%ds)\n" "$elapsed"
break
fi
printf "."
sleep 2
elapsed=$((elapsed + 2))
done
if [ $elapsed -ge $TIMEOUT ]; then
printf " ${RED}timeout after %ds${NC}\n" "$TIMEOUT"
echo "Node-RED did not become ready. Check logs with: docker compose logs nodered"
exit 1
fi
echo ""
# ---------------------------------------------------------
# Fetch loaded nodes from admin API
# ---------------------------------------------------------
NODES_JSON=$(curl -sf "$NODERED_URL/nodes" 2>/dev/null)
if [ -z "$NODES_JSON" ]; then
echo "${RED}ERROR${NC}: Failed to fetch /nodes from Node-RED"
exit 1
fi
# ---------------------------------------------------------
# Check each expected node
# ---------------------------------------------------------
LOADED=0
MISSING=0
for node in $EXPECTED_NODES; do
# Check if the node type appears in the loaded nodes response
if echo "$NODES_JSON" | grep -qi "\"$node\""; then
printf " ${GREEN}LOADED${NC} %s\n" "$node"
LOADED=$((LOADED + 1))
else
printf " ${RED}MISSING${NC} %s\n" "$node"
MISSING=$((MISSING + 1))
fi
done
# ---------------------------------------------------------
# Summary
# ---------------------------------------------------------
echo ""
TOTAL=$((LOADED + MISSING))
echo "=============================================="
printf " Results: ${GREEN}%d loaded${NC}, ${RED}%d missing${NC} (of %d expected)\n" \
"$LOADED" "$MISSING" "$TOTAL"
echo "=============================================="
if [ $MISSING -gt 0 ]; then
echo ""
echo "Some nodes failed to load. Check Node-RED logs:"
echo " docker compose logs nodered | grep -i error"
exit 1
fi
exit 0