Files
NetAlertX/front/plugins/pihole_scan
sebingel 4c117db463 Fix elementOptions: rename typo 'ordeable' to 'orderable'
The key 'ordeable' in elementOptions was a long-standing typo for the
correct English word 'orderable'. Since the JS check in settings_utils.js
used the same misspelled key, the feature appeared to work — but it was
relying on the consistent propagation of a typo across the entire codebase.

Two pre-existing entries in front/plugins/ui_settings/config.json already
used the correct spelling 'orderable', but these had no effect because the
JavaScript check (option.ordeable === 'true') never matched them. As a
result, orderable behavior was silently disabled for those two settings.

Changes:
- front/js/settings_utils.js: renamed option.ordeable → option.orderable
  and isOrdeable → isOrderable (6 occurrences, lines 792/823/824/880/1079/
  1192/1228). The JS key check is the authoritative definition of the
  elementOptions property name, so this must change atomically with all
  config files.

- server/initialise.py:245: renamed "ordeable" → "orderable" in the
  hardcoded JSON string for LOADED_PLUGINS setting. This string is the
  source-of-truth for that setting's elementOptions and is not auto-
  generated from the plugin config files.

- front/plugins/*/config.json (33 files, 90 occurrences): renamed all
  "ordeable": "true" entries to "orderable": "true" via sed. All plugins
  used the typo consistently; they must be updated in the same commit to
  avoid a broken intermediate state.

The two formerly broken 'orderable' entries in ui_settings/config.json
are now matched by the corrected JS check and work as intended.

Fixes netalertx/NetAlertX#1584

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-03 18:28:48 +00:00
..

Overview

A plugin allowing for importing devices from the PiHole database. This is an import plugin using an SQLite database as a source.

Usage

  • You need to specify the following settings:
    • PIHOLE_RUN is used to enable the import by setting it e.g. to schedule or once (pre-set to disabled)
    • PIHOLE_RUN_SCHD is to configure how often the plugin is executed if PIHOLE_RUN is set to schedule (pre-set to every 30 min)
    • PIHOLE_DB_PATH setting must match the location of your PiHole database (pre-set to /etc/pihole/pihole-FTL.db)

Troubleshooting

Permission problems:

NetAlertX cannot read Pi-hole DB (/etc/pihole/pihole-FTL.db) due to permissions:

[Plugins] ⚠ ERROR: ATTACH DATABASE failed with SQL ERROR: unable to open database: /etc/pihole/pihole-FTL.db

Solution:

  1. Mount full Pi-hole directory (read-only):
volumes:
  - /etc/pihole:/etc/pihole:ro
  1. Add NetAlertX to Pi-hole group:
group_add:
  - 1001  # check with `getent group pihole`

Verify:

docker exec -it netalertx id
# groups=1001,...  ✅ pihole group included

Notes:

  • Avoid mounting single DB files.
  • Keep mount read-only (:ro) to protect Pi-hole data.
  • Use group_add instead of chmod.