-
Notifications
You must be signed in to change notification settings - Fork 37
Description
Is your feature request related to a problem? Please describe.
Currently, Nebula-Sync can trigger a pihole -g (gravity update) after each synchronization when RUN_GRAVITY is set to true.
However, this will rebuild gravity even if there were no changes to any blocklists — for example, when only whitelist/allowlist entries or groups were modified.
This can be unnecessarily resource-intensive on lower-end devices (like Raspberry Pis), especially for users with large blocklists, since pihole -g temporarily locks the Pi-hole database and restarts FTL.
Describe the solution you'd like
Add a configuration option such as:
run_gravity: conditional
gravity_condition: adlist_changes_only
or a boolean like:
run_gravity_on_adlist_change: true
to make Nebula-Sync trigger a gravity rebuild only if one or more Adlists were added, removed, or modified.
Expected:
When Adlists (blocklists) differ between Master and Slave → run pihole -g
When only Whitelist / Blacklist / Regex / DHCP / Group changes occur → skip gravity
Optional log line:
"[INFO] Skipping gravity update (no Adlist changes detected)."
Why this matters:
This would significantly reduce unnecessary system load on devices with large Gravity databases, while keeping filtering consistent whenever actual blocklist updates occur.
Describe alternatives you've considered
No response
Anything else?
Environment:
- My use case: Master Pi-hole in Proxmox (LXC), Slave Pi-hole on Raspberry Pi3
- Both synchronized via Nebula-Sync Docker setup
- 10–15 million blocked domains total
Thanks for considering!
This would make Nebula-Sync even more efficient and user-friendly for larger installations.