mirror of
https://github.com/ajvpot/meshexplorer.git
synced 2026-06-12 02:04:49 +02:00
83978609f0
Vendor the ingest service under ingest/ and move the web app under meshexplorer/. The ingest builds the meshcoreingest daemon and the goose migration runner, applies the meshcore ClickHouse schema (packets, adverts, unified node view), and loads its MQTT broker list and ClickHouse settings entirely from environment variables (MQTT_BROKERS as a JSON array, CLICKHOUSE_*). No credentials are baked into the source. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
20 lines
595 B
SQL
20 lines
595 B
SQL
-- +goose Up
|
|
-- Unified latest node info view.
|
|
-- MeshCore is the only supported protocol, so this is a thin projection over
|
|
-- meshcore_adverts_latest that the web app (getNodePositions) reads from.
|
|
CREATE OR REPLACE VIEW unified_latest_nodeinfo AS
|
|
SELECT
|
|
public_key AS node_id,
|
|
node_name AS name,
|
|
substringUTF8(node_name, 1, 1) AS short_name,
|
|
latitude AS latitude,
|
|
longitude AS longitude,
|
|
first_heard AS first_seen,
|
|
last_seen,
|
|
'meshcore' AS type
|
|
FROM meshcore_adverts_latest
|
|
ORDER BY last_seen DESC;
|
|
|
|
-- +goose Down
|
|
DROP VIEW IF EXISTS unified_latest_nodeinfo;
|