caf7ef4cc866438ed3b7fa06ac1398e2bbf626af
7
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
5217c6e333 |
feat(fixes): ZabbixAgentMixin, a native Zabbix agent for a host without a container engine (NetOrk/netork#2571)
driver / lint (pull_request) Successful in 16s
driver / standard (pull_request) Successful in 18s
driver / types (pull_request) Successful in 49s
driver / test (3.13) (pull_request) Successful in 1m6s
driver / lowest (pull_request) Successful in 34s
driver / test (3.12) (pull_request) Successful in 1m11s
driver / build (pull_request) Successful in 24s
driver / security (pull_request) Successful in 55s
CI / driver (pull_request) Successful in 2m20s
driver / publish (pull_request) Skipped
configure_zabbix_agent(settings) loads the package index where the driver can, installs ZABBIX_AGENT_PACKAGE from the host's own packages and, where those have none and settings["release"] names the server's release line, from Zabbix's repository (the driver's _add_zabbix_repository); then the driver writes the configuration and opens the firewall, and the service is enabled and restarted. Settings that do not hold raise ValueError before anything changes. zabbix_agent.py holds what is the same on every host, without I/O: the settings check, the agent's configuration with Server, ServerActive, ListenPort and Hostname set and the rest kept, and the root command that adds Zabbix's repository for Debian, Ubuntu, Raspberry Pi OS and the RHEL family, in the layout before and since 7.2. LldpAgentMixin and ZabbixAgentMixin share the start step (enable_and_restart). |
||
|
|
b4cdcfd347 |
fix(dhcp): release an address before another reservation takes it
driver / standard (pull_request) Successful in 17s
driver / lint (pull_request) Successful in 14s
driver / types (pull_request) Successful in 1m3s
driver / test (3.12) (pull_request) Successful in 1m25s
driver / test (3.13) (pull_request) Successful in 1m13s
driver / lowest (pull_request) Successful in 45s
driver / build (pull_request) Successful in 32s
driver / security (pull_request) Successful in 1m10s
CI / driver (pull_request) Successful in 3m6s
driver / publish (pull_request) Skipped
apply_dhcp_reservationset wrote adds first, then updates in the order of the desired set. Kea keeps addresses unique at each write, so when an address moved from one reservation to another, the reservation taking it was refused as a duplicate whenever it came first. The changes are now ordered (_dhcp_order): an update that moves a reservation off its address goes before the change that takes that address, along a chain from its free end, and adds come after every update. A swap or rotation of addresses has no such order; its changes are still tried, so a server that checks only at the commit takes them, and a refused one's [failed] line says it was a swap and with which reservations. Nothing is moved to a temporary address: the contract knows no free one, and a failed second write would leave it there. The diff is computed against one read of the reservations, shared with diff_dhcp_reservations. Refused rows still do not stop the others, the rest is committed and DhcpApplyError follows, as since 4.35.1. Closes #106 |
||
|
|
58ed0f0a94 |
feat(host-status): tell an interrupted dnf, yum, apk or opkg
driver / standard (pull_request) Failing after 18s
driver / lint (pull_request) Successful in 17s
driver / types (pull_request) Successful in 1m9s
driver / test (3.12) (pull_request) Successful in 1m22s
driver / lowest (pull_request) Successful in 39s
driver / build (pull_request) Successful in 36s
driver / test (3.13) (pull_request) Successful in 2m14s
driver / security (pull_request) Failing after 1m1s
CI / driver (pull_request) Failing after 2m42s
driver / publish (pull_request) Skipped
get_host_status() read only dpkg's state. It now also reads the rpm database and dnf's history (or yum's journal), apk's installed database and opkg's status file, without root, and names the manager it read in the new package_manager field. While one of them runs, the answer is unknown, as for dpkg. Refs NetOrk/netork#851 |
||
|
|
95e3aa1e26 |
feat(backup): BackupServerDriver, a role base for backup servers (#82)
driver / lint (pull_request) Successful in 15s
driver / standard (pull_request) Successful in 16s
driver / types (pull_request) Successful in 1m6s
driver / test (3.13) (pull_request) Successful in 1m7s
driver / test (3.12) (pull_request) Successful in 1m15s
driver / lowest (pull_request) Successful in 30s
driver / build (pull_request) Successful in 29s
driver / security (pull_request) Successful in 58s
CI / driver (pull_request) Successful in 2m22s
driver / publish (pull_request) Skipped
A backup server keeps datastores, one backup group per source with its snapshots, and the jobs that keep them healthy: garbage collection, verify, prune, sync and tape. None of that is a pool, a volume or a replication job, so it is a role of its own instead of being bent into StorageDriver. A server that manages its own disks lists StorageDriver second. The role declares the reads (datastores, groups with their newest snapshot, a group's snapshots, jobs, remotes) and the actions (garbage collection, running a job, verifying, protecting and deleting a snapshot), which start a task and return its id for get_backup_task. The shapes live in napalm_device_types.backups. ClusterStorageDict gains an optional backup_server: which server, datastore and namespace a hypervisor's backup storage writes to, with the fingerprint it pins. Matching that to a server is the application's. |
||
|
|
3490d8b62a |
docs(structure): format the code examples as current ruff does
driver / standard (pull_request) Successful in 21s
driver / lint (pull_request) Successful in 17s
driver / types (pull_request) Successful in 1m5s
driver / test (3.12) (pull_request) Successful in 1m14s
driver / test (3.13) (pull_request) Successful in 1m7s
driver / lowest (pull_request) Successful in 34s
driver / build (pull_request) Successful in 32s
driver / security (pull_request) Successful in 1m29s
CI / driver (pull_request) Successful in 3m21s
driver / publish (pull_request) Skipped
ruff 0.17 formats Python blocks in Markdown too, and CI installs ruff unpinned, so the lint job on main failed on docs/STRUCTURE.md. Closes #79 |
||
|
|
c7ea15dbb4 |
docs: what the drivers need from the SNMP profile, opt-outs, and how getters behave
CI / test (3.10) (push) Successful in 26s
CI / test (3.11) (push) Successful in 24s
CI / test (3.12) (push) Successful in 26s
CI / test (3.13) (push) Successful in 25s
CI / test (3.10) (pull_request) Successful in 25s
CI / test (3.11) (pull_request) Successful in 24s
CI / test (3.12) (pull_request) Successful in 26s
CI / test (3.13) (pull_request) Successful in 25s
The SNMP profile has to express fallback OIDs, tables folded by first, average or maximum, numbers inside text values, memory as used, free or percent, and the uptime source. TX errors counting drops becomes OPNsense's entry instead of every firewall's. A driver opts out of an inherited template with None, so callers ask callable(). USES_SSH, FULL_UPGRADE and platform stay as driver facts. Getters do not write, a failed read raises, a write reports its real result, and the application uses public driver methods only. |
||
|
|
01fe680456 |
docs: a structure that keeps device-types vendor- and product-agnostic
CI / test (3.10) (push) Successful in 28s
CI / test (3.11) (push) Successful in 26s
CI / test (3.12) (push) Successful in 27s
CI / test (3.13) (push) Successful in 25s
CI / test (3.10) (pull_request) Successful in 25s
CI / test (3.11) (pull_request) Successful in 24s
CI / test (3.12) (pull_request) Successful in 25s
CI / test (3.13) (pull_request) Successful in 24s
Roles and capabilities declare, templates run declared steps, reconcilers stay free of I/O. POSIX host readers, the SSH exec transport and the privilege layer move to a new package, napalm-unix. SNMP polling, ping sweeps, discovery scoring, guest profiles, display labels and warnings belong to the application; drivers declare SNMP OIDs as data and report facts. Fixes become templates whose values come from the caller. Says in which order this happens and where the open proposals #8-#14 and #22 go instead. |