fix(time-sync): switch off the POSIX time sync on QTS
driver / standard (pull_request) Successful in 17s
driver / lint (pull_request) Successful in 16s
driver / types (pull_request) Successful in 1m9s
driver / test (3.12) (pull_request) Successful in 1m6s
driver / test (3.13) (pull_request) Successful in 1m1s
driver / lowest (pull_request) Successful in 34s
driver / build (pull_request) Successful in 28s
driver / security (pull_request) Successful in 1m12s
CI / driver (pull_request) Successful in 2m51s
driver / publish (pull_request) Skipped
driver / standard (pull_request) Successful in 17s
driver / lint (pull_request) Successful in 16s
driver / types (pull_request) Successful in 1m9s
driver / test (3.12) (pull_request) Successful in 1m6s
driver / test (3.13) (pull_request) Successful in 1m1s
driver / lowest (pull_request) Successful in 34s
driver / build (pull_request) Successful in 28s
driver / security (pull_request) Successful in 1m12s
CI / driver (pull_request) Successful in 2m51s
driver / publish (pull_request) Skipped
napalm-linux now brings napalm-device-types' PosixTimeSyncMixin (4.35.0). QTS has no systemd and no timedatectl, and its NTP client and time zone are QTS settings: the inherited reading finds no client there and every write fails its step, a difference netOrk could report on every poll but never fix (NetOrk/netork#2370). get_time_sync and configure_time_sync are None, so a capability check answers no, until a QTS variant is built against a real box. The floor rises to napalm-device-types 4.35.0.
This commit is contained in:
1 parent
28eb954eda
commit
f1d191c52a
5 files changed
+25
-1
No files matched your search
@@ -8,6 +8,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
- `get_time_sync` and `configure_time_sync`, which napalm-linux brings through
|
||||||
|
napalm-device-types' `PosixTimeSyncMixin` (4.35.0), are switched off: QTS has no systemd
|
||||||
|
and no `timedatectl`, and its NTP client and time zone are QTS settings. The POSIX
|
||||||
|
reading would find no client and every write would fail, a difference netOrk could
|
||||||
|
never fix (NetOrk/netork#2370). Needs napalm-device-types 4.35.0.
|
||||||
- `remove_local_account_keys`, which napalm-linux 0.17.0 brings, is switched off like the
|
- `remove_local_account_keys`, which napalm-linux 0.17.0 brings, is switched off like the
|
||||||
other personal-account actions: QTS manages its users in its own UI (NetOrk/netork#2013).
|
other personal-account actions: QTS manages its users in its own UI (NetOrk/netork#2013).
|
||||||
Needs napalm-device-types 4.28.0 and napalm-linux 0.17.0.
|
Needs napalm-device-types 4.28.0 and napalm-linux 0.17.0.
|
||||||
|
|||||||
@@ -39,6 +39,7 @@ output is how a driver ends up passing its own tests and failing on a real NAS.
|
|||||||
| `manage_scheduled_job` | the crontab, then `crontab` + `crond.sh restart`; the firmware's lines only run | ✅ synthetic fixtures |
|
| `manage_scheduled_job` | the crontab, then `crontab` + `crond.sh restart`; the firmware's lines only run | ✅ synthetic fixtures |
|
||||||
| `put_scheduled_job`, `delete_scheduled_job` | marked lines in `/etc/config/crontab`, as admin | ✅ synthetic fixtures |
|
| `put_scheduled_job`, `delete_scheduled_job` | marked lines in `/etc/config/crontab`, as admin | ✅ synthetic fixtures |
|
||||||
| `ping`, `ping_sweep` | inherited from `LinuxDriver` | ✅ |
|
| `ping`, `ping_sweep` | inherited from `LinuxDriver` | ✅ |
|
||||||
|
| `get_time_sync`, `configure_time_sync` | — (QTS settings; no systemd or `timedatectl`) | switched off until a QTS variant (NetOrk/netork#2370) |
|
||||||
| Snapshots, quotas, replication, QPKG install/remove | — | out of scope for v1 |
|
| Snapshots, quotas, replication, QPKG install/remove | — | out of scope for v1 |
|
||||||
|
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|||||||
@@ -103,6 +103,11 @@ class QnapQtsDriver(StorageDriver, HypervisorDriver, QtsScheduledJobsMixin, Linu
|
|||||||
lock_local_account = None # type: ignore[assignment]
|
lock_local_account = None # type: ignore[assignment]
|
||||||
add_service_account = None # type: ignore[assignment]
|
add_service_account = None # type: ignore[assignment]
|
||||||
remove_local_account_keys = None # type: ignore[assignment]
|
remove_local_account_keys = None # type: ignore[assignment]
|
||||||
|
#: QTS has no systemd and no timedatectl; its NTP client and zone are QTS
|
||||||
|
#: settings. LinuxDriver's POSIX time sync would read no client and fail every
|
||||||
|
#: write: off until a QTS variant is built against a real box (NetOrk/netork#2370).
|
||||||
|
get_time_sync = None # type: ignore[assignment]
|
||||||
|
configure_time_sync = None # type: ignore[assignment]
|
||||||
|
|
||||||
SNMP_OBJECT_ID_PREFIX = QNAP_ENTERPRISE_OID
|
SNMP_OBJECT_ID_PREFIX = QNAP_ENTERPRISE_OID
|
||||||
SNMP_FINGERPRINT = [
|
SNMP_FINGERPRINT = [
|
||||||
|
|||||||
+1
-1
@@ -40,7 +40,7 @@ classifiers = [
|
|||||||
# processes, Docker) from LinuxDriver rather than reimplementing it.
|
# processes, Docker) from LinuxDriver rather than reimplementing it.
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"napalm>=4.0",
|
"napalm>=4.0",
|
||||||
"napalm-device-types>=4.28.0",
|
"napalm-device-types>=4.35.0",
|
||||||
"napalm-linux>=0.17.0",
|
"napalm-linux>=0.17.0",
|
||||||
"netmiko>=4.0.0",
|
"netmiko>=4.0.0",
|
||||||
"paramiko>=5.0.0", # CVE-2026-44405
|
"paramiko>=5.0.0", # CVE-2026-44405
|
||||||
|
|||||||
@@ -248,6 +248,19 @@ def test_personal_accounts_are_not_managed_here():
|
|||||||
assert not callable(getattr(QnapQtsDriver, action, None))
|
assert not callable(getattr(QnapQtsDriver, action, None))
|
||||||
|
|
||||||
|
|
||||||
|
def test_time_sync_is_not_read_or_set_here():
|
||||||
|
"""QTS has no systemd and no ``timedatectl``, and its NTP client and zone are QTS
|
||||||
|
settings: the POSIX reading inherited from LinuxDriver finds no client there, and
|
||||||
|
its write fails. Off until a QTS variant is built against a real box
|
||||||
|
(NetOrk/netork#2370), so netOrk neither reports a difference it cannot fix nor
|
||||||
|
tries to fix it."""
|
||||||
|
from napalm_linux.linux import LinuxDriver
|
||||||
|
|
||||||
|
for method in ("get_time_sync", "configure_time_sync"):
|
||||||
|
assert callable(getattr(LinuxDriver, method, None)), method
|
||||||
|
assert not callable(getattr(QnapQtsDriver, method, None)), method
|
||||||
|
|
||||||
|
|
||||||
class TestFixesQtsCannotTake:
|
class TestFixesQtsCannotTake:
|
||||||
"""QTS has no apt, dnf or opkg, and its SNMP agent is configured in its own UI:
|
"""QTS has no apt, dnf or opkg, and its SNMP agent is configured in its own UI:
|
||||||
the fix templates inherited from LinuxDriver are switched off (#7), so a
|
the fix templates inherited from LinuxDriver are switched off (#7), so a
|
||||||
|
|||||||
Reference in new issue
Block a user