feat(system_baseline): reboot one host at a time and bound a hung apt-daily.service
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
This commit is contained in:
1 parent
8da65bd08e
commit
7092d68822
14 files changed
+239
-3
No files matched your search
@@ -0,0 +1,24 @@
|
||||
---
|
||||
# A hung apt-daily.service (a stuck mirror, a dpkg lock that never frees) blocks the next apt run on the host for as long as systemd lets
|
||||
# it start. A drop-in bounds the start. Only apt-daily.service: apt-daily-upgrade.service is left to its own timeout.
|
||||
- name: Ensure the apt-daily drop-in directory exists
|
||||
become: true
|
||||
ansible.builtin.file:
|
||||
path: /etc/systemd/system/apt-daily.service.d
|
||||
state: directory
|
||||
owner: root
|
||||
group: root
|
||||
mode: "0755"
|
||||
|
||||
- name: Bound the start of apt-daily.service
|
||||
become: true
|
||||
ansible.builtin.copy:
|
||||
dest: /etc/systemd/system/apt-daily.service.d/10-timeout.conf
|
||||
content: |
|
||||
# Managed by Ansible (role system_baseline).
|
||||
[Service]
|
||||
TimeoutStartSec={{ system_baseline_apt_daily_timeout }}
|
||||
owner: root
|
||||
group: root
|
||||
mode: "0644"
|
||||
notify: Reload systemd for apt-daily timeout
|
||||
Reference in new issue
Block a user