From 372c3dc09d1895437cbef5e14e0dc009eff084f5 Mon Sep 17 00:00:00 2001 From: Samuel James Date: Thu, 3 Sep 2026 16:04:57 +0000 Subject: [PATCH] thinkcenter-xrdp: add dpkg/apt self-heal step (prevents half-configured-package cascade failures) --- life-church/playbooks/thinkcenter-xrdp.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/life-church/playbooks/thinkcenter-xrdp.yml b/life-church/playbooks/thinkcenter-xrdp.yml index 5b228e3..c63c27b 100644 --- a/life-church/playbooks/thinkcenter-xrdp.yml +++ b/life-church/playbooks/thinkcenter-xrdp.yml @@ -85,6 +85,14 @@ that: inventory_hostname == 'thinkcenter' fail_msg: "Refusing to run — this play is scoped to thinkcenter only." + - name: "[selfheal] Repair any half-configured dpkg/apt state (prevents cascade failures)" + ansible.builtin.shell: | + dpkg --configure -a || true + apt-get -y -f install || true + register: dpkg_selfheal + changed_when: "'Setting up' in (dpkg_selfheal.stdout | default(''))" + failed_when: false + - name: "[apt] Install xrdp packages (no-op if already present)" ansible.builtin.apt: name: "{{ xrdp_packages }}"