diff --git a/napalm_openmediavault/__pycache__/openmediavault.cpython-312.pyc b/napalm_openmediavault/__pycache__/openmediavault.cpython-312.pyc index 96a292f..6022e63 100644 Binary files a/napalm_openmediavault/__pycache__/openmediavault.cpython-312.pyc and b/napalm_openmediavault/__pycache__/openmediavault.cpython-312.pyc differ diff --git a/napalm_openmediavault/openmediavault.py b/napalm_openmediavault/openmediavault.py index f9602f6..7fbe13d 100644 --- a/napalm_openmediavault/openmediavault.py +++ b/napalm_openmediavault/openmediavault.py @@ -33,26 +33,25 @@ from napalm_device_types.models import ( StorageServiceDict, VolumeSnapshotDict, ) +from napalm_device_types import StorageDriver from napalm_linux.linux import LinuxDriver -class OpenMediaVaultDriver(LinuxDriver): +class OpenMediaVaultDriver(StorageDriver, LinuxDriver): """NAPALM driver for OpenMediaVault NAS systems. - Inherits all Linux OS functionality from LinuxDriver (packages, - services, users, processes, cron, Docker) and adds OMV-specific - storage management capabilities. + Declares both roles it fills: a NAS built on Debian. Storage comes first, + so netOrk shows it as storage rather than as a Linux host. - NAS services are exposed via ``get_storage_services()`` to avoid a - naming collision with LinuxDriver's ``get_services()`` (which returns - the full systemd service list). + Inherits all Linux OS functionality from LinuxDriver (packages, services, + users, processes, cron, Docker) -- OMV really is Debian, so apt applies -- + and adds OMV-specific storage management on top. + + NAS services are ``get_storage_services()``; the systemd service list stays + ``get_services()``. Two names for two different things. """ TYPE_LABEL = "Storage" - # Declared outright: the driver inherits LinuxDriver for the OS surface, so - # the issubclass chain would otherwise classify an OMV NAS as "linux" and - # the UI would never render its Storage tab. - DEVICE_CLASS = "storage" DRIVER_NAME = "openmediavault" driver_name = "openmediavault" SSH_FINGERPRINT = [