disallow server start if at least one list parsed with errors; add initial listing api

This commit is contained in:
yggverse 2026-03-27 13:09:08 +02:00
parent 0b08744f8f
commit 752ea23f80
4 changed files with 111 additions and 36 deletions

View file

@ -22,9 +22,11 @@ RUST_LOG=trace cargo run -- --allow=http://localhost/allow.txt \
```
* set `socks5://127.0.0.1:1080` proxy in your application
* use http://127.0.0.1:8010 for API:
* `/api/allow/{domain.com}` - add rule to the current session
* `/api/block/{domain.com}` - delete rule from the current session
* `/api/allow/<domain.com>` - add rule to the current session
* `/api/block/<domain.com>` - delete rule from the current session
* `/api/rules` - return active rules (from server memory)
* `/api/lists` - get parsed lists with its ID
* `/api/list/<ID>` - get all parsed rules for list ID (see `/api/lists`)
### Allow list example