mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2026-04-04 09:11:34 -07:00
feat: implement hybrid native/python speedtest engine
- Introduce native Ookla Speedtest binary support for Gigabit connections - Add intelligent engine detection with automatic fallback to python-cli version - Map full JSON payload to Watched_Value3 for n8n integration - Add Spanish (es_es) localizations and update README instructions
This commit is contained in:
@@ -1,11 +1,33 @@
|
||||
## Overview
|
||||
|
||||
A simple plugin allowing for executing regular internet speed tests.
|
||||
A plugin allowing for executing regular internet speed tests.
|
||||
|
||||
### Usage
|
||||
|
||||
- N/A
|
||||
This plugin supports two engines:
|
||||
1. **Baseline Engine**: Uses the Python `speedtest-cli` library (default).
|
||||
2. **Native Engine (Optimized)**: Uses the native Ookla Speedtest binary.
|
||||
|
||||
#### Opt-in for Native Engine
|
||||
To use the native engine:
|
||||
- Provide the native `speedtest` binary in your environment: [Speedtest CLI Homepage](https://www.speedtest.net/apps/cli)
|
||||
- Map the binary to `/usr/bin/speedtest` in the container.
|
||||
- **Ensure the native speedtest binary is installed on the host at the source path.**
|
||||
|
||||
```yaml
|
||||
volumes:
|
||||
- /usr/bin/speedtest:/usr/bin/speedtest:ro
|
||||
```
|
||||
- The plugin will automatically detect and use it for subsequent tests.
|
||||
|
||||
|
||||
### Data Mapping
|
||||
|
||||
- **Watched_Value1** — Download Speed (Mbps).
|
||||
- **Watched_Value2** — Upload Speed (Mbps).
|
||||
- **Watched_Value3** — Full JSON payload (useful for n8n or detailed webhooks).
|
||||
|
||||
### Notes
|
||||
|
||||
- N/A
|
||||
- The native binary is recommended for connections > 100 Mbps.
|
||||
- If the native binary is not detected, the plugin seamlessly falls back to the baseline library.
|
||||
Reference in New Issue
Block a user