The custom network-exporter script exposes Speedtest and SmokePing data to Prometheus.
This page documents the network-exporter service defined under /srv/docker/network-exporter.
- Container:
network-exporter
- Image: built from
logs-network-exporter (local build)
- Stack: Logs Stack
- Docker network:
logs_loki
- Restart policy:
unless-stopped
- Internal listener:
9877/tcp
¶ Config and Data Paths
- Source directory:
/srv/docker/network-exporter
- Key files:
Dockerfile and exporter.py
- It reads
/srv/docker/speedtest-tracker/config/database.sqlite and /srv/docker/smokeping/data
- Only
logs_loki members can reach port 9877
- Prometheus scrapes the exporter via the
network-exporter job
¶ Authentication and Secret Locations
- All configuration is in Python; no secrets are persisted on the host
- Ensure the Speedtest and SmokePing directories remain writable for the exporter
- After changing Speedtest servers or probe targets, restart the exporter so it reloads the SQLite state
¶ Monitoring and Logs
- Docker logging driver is
json-file
- Logs come from the custom Python script's stdout
¶ Backup and Restore
/srv/docker/network-exporter is covered by Duplicati because it lives under /srv/docker
- Preserve both the exporter source and the Speedtest/SmokePing data paths
¶ Failure Modes and Recovery
- If the SQLite DB is locked, the exporter stops serving metrics even though the container stays running
- Without the Speedtest or SmokePing directories, there is nothing to export, so Prometheus alerts will trigger for missing targets