Add system_baseline_reboot_throttle and system_baseline_reboot_post_delay, passed to the throttle and post_reboot_delay of the reboot task, read by the main flow and by tasks_from: reboot, both defaulting to 0 (today's behaviour) and validated in both. Add system_baseline_apt_daily_timeout: when set, write a TimeoutStartSec drop-in for apt-daily.service and reload systemd. Empty by default, which leaves the host alone. Closes #336 Closes #337 Assisted-by: Claude Code
14 lines
761 B
YAML
14 lines
761 B
YAML
---
|
|
# Shared by validate.yml and reboot.yml: the tasks_from: reboot entry point does not run validate.yml. A negative or non-integer value
|
|
# must stop the run before a host reboots, not be coerced into a different wait. `| string` also refuses true, 2.5 and a list.
|
|
- name: Validate the reboot throttle and post-reboot delay
|
|
ansible.builtin.assert:
|
|
that:
|
|
- system_baseline_reboot_throttle | string is match('^[0-9]+\Z')
|
|
- system_baseline_reboot_post_delay | string is match('^[0-9]+\Z')
|
|
fail_msg: >-
|
|
system_baseline_reboot_throttle ('{{ system_baseline_reboot_throttle }}') and system_baseline_reboot_post_delay
|
|
('{{ system_baseline_reboot_post_delay }}') must each be a whole number, 0 or more.
|
|
quiet: true
|
|
tags: always
|