refactor: 边缘节点与配置精简

- 边缘: Prometheus 改为 vmagent,统一 docker-compose.yml,内存+磁盘缓存
- 边缘脚本: 合并为 deploy.sh [--local],删除 run-edge-local、quick-setup、run-edge-with-cache
- 配置: 合并为 update-configs.sh,统一 targets.csv,生成 target-onvif/target-ping/target-topology
- 删除 topology-editor、旧格式 devices.csv/ping-targets.csv、setup-remote-write、test-connection
- 文档: 更新 EDGE_CACHE、TIANDITU(瓦片改 4090 直连 tile-cache)

Made-with: Cursor
This commit is contained in:
User
2026-02-28 19:44:46 -05:00
parent 72a5bf30b4
commit 650e5145f1
35 changed files with 319 additions and 2774 deletions

View File

@@ -8,8 +8,8 @@ remote_write:
- url: http://${CENTRAL_SERVER_HOST}:${CENTRAL_SERVER_PORT}/api/v1/write
queue_config:
max_samples_per_send: 5000
capacity: 5000
max_shards: 5
capacity: 10000
max_shards: 8
scrape_configs:
- job_name: 'onvif-devices'

View File

@@ -0,0 +1,40 @@
# vmagent 抓取配置(与 prometheus.yml 兼容,自监控端口改为 8429
# 如需修改 region可编辑此文件或通过 deploy.sh 从 vmagent-scrape.yml.template 生成
global:
scrape_interval: 120s
evaluation_interval: 120s
external_labels:
region: workernode_1
scrape_configs:
- job_name: 'onvif-devices'
scrape_interval: 120s
file_sd_configs:
- files: ['/etc/prometheus/target-onvif.json']
refresh_interval: 5m
metrics_path: /metrics
static_configs:
- targets: ['onvif-exporter:9600']
- job_name: 'network-ping'
scrape_interval: 300s
file_sd_configs:
- files: ['/etc/prometheus/target-ping.json']
refresh_interval: 5m
metrics_path: /probe
params:
module: [icmp]
static_configs:
- targets: ['blackbox-exporter:9115']
relabel_configs:
- source_labels: [__address__]
target_label: __param_target
- source_labels: [__param_target]
target_label: instance
- target_label: __address__
replacement: blackbox-exporter:9115
- job_name: 'vmagent-edge'
scrape_interval: 60s
static_configs:
- targets: ['localhost:8429']