From 7bd0790d6dd2aef7cae891da0e8a8132e86aba89 Mon Sep 17 00:00:00 2001 From: Drew Newberry Date: Tue, 28 Jul 2026 14:54:09 -0700 Subject: [PATCH] fix(test-guest): refresh runtime setup state Signed-off-by: Drew Newberry --- nix/test-guest/configuration/podman.yml | 6 ++++-- nix/test-guest/run.sh | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/nix/test-guest/configuration/podman.yml b/nix/test-guest/configuration/podman.yml index 2872f5cbf..a1139b4f6 100644 --- a/nix/test-guest/configuration/podman.yml +++ b/nix/test-guest/configuration/podman.yml @@ -22,9 +22,11 @@ update_cache: true when: ansible_facts.distribution == "Ubuntu" - - name: Install Podman + - name: Install Podman dependencies ansible.builtin.package: - name: podman + name: + - podman + - socat state: present - name: Enable the rootless Podman API socket diff --git a/nix/test-guest/run.sh b/nix/test-guest/run.sh index 4dffd530d..095d854d8 100644 --- a/nix/test-guest/run.sh +++ b/nix/test-guest/run.sh @@ -425,6 +425,11 @@ else echo "==> Reusing cached configuration: ${configurations[*]:-base image}" fi +# Configuration may change the test user's groups. Close the SSH control +# connection established before provisioning so subsequent commands start with +# the guest's current credentials. +ssh "${ssh_args[@]}" -O exit openshell@127.0.0.1 >/dev/null 2>&1 || true + for package in "${packages[@]}"; do package_name=$(basename "${package}") if [[ ! ${package_name} =~ ^[A-Za-z0-9._+~-]+$ ]]; then