feat(scheduled-jobs): scheduled jobs through PosixScheduledJobsMixin (#67)
driver / standard (pull_request) Successful in 16s
driver / lint (pull_request) Successful in 13s
driver / test (3.12) (pull_request) Failing after 51s
driver / types (pull_request) Failing after 59s
driver / test (3.13) (pull_request) Failing after 47s
driver / lowest (pull_request) Failing after 29s
driver / build (pull_request) Successful in 30s
driver / security (pull_request) Failing after 1m14s
CI / driver (pull_request) Failing after 2m29s
driver / publish (pull_request) Skipped

get_scheduled_jobs reads /etc/crontab, /etc/cron.d, the user crontabs,
run-parts, anacron and every systemd timer in one round trip as root;
manage_scheduled_job enables, disables or runs one now; put_ and
delete_scheduled_job write and remove an application's own job.

get_cron_jobs goes: it read without root, missed most of what a host
schedules, and nothing called it.

Requires napalm-device-types 4.26.0.

Closes #67
This commit is contained in:
Christian Manivong committed 2026-11-03 05:32:01 +01:00
1 parent cb0e308a78
commit ca32b89686
7 files changed
+77 -110

No files matched your search

+11
View File
@@ -8,6 +8,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
### Added
- Scheduled jobs (NetOrk/netork#1933, #67), through napalm-device-types' `PosixScheduledJobsMixin`:
`get_scheduled_jobs()` reads `/etc/crontab`, `/etc/cron.d`, the user crontabs (Debian,
RHEL, Alpine), the run-parts directories, `/etc/anacrontab` and every systemd timer in one
round trip as root; `manage_scheduled_job()` enables, disables or runs one now;
`put_scheduled_job()` and `delete_scheduled_job()` write and remove an application's own.
OpenMediaVault and QNAP QTS inherit it and decide per verb in their own packages.
- netOrk's own account with a fixed uid (NetOrk/netork#1817): `_account_create_with_uid`
makes it with `useradd -m -u <uid>`. Below `UID_MIN` useradd warns and goes on, as a
system's account.
@@ -122,6 +128,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
calls its default route `default` as well. An IPv6 host route is now a `/128`
instead of a `/32`.
### Removed
- `get_cron_jobs()`: it read without root, missed other users' crontabs, `/etc/crontab`,
run-parts, anacron and every systemd timer, and nothing called it. `get_scheduled_jobs()`
replaces it.
## [0.15.1] - 2026-10-23
### Fixed