From 1029cccc11abe59a9bd0922ce639c2d113f8f1ac Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 1 Mar 2026 00:53:23 -0700 Subject: [PATCH] Add host_vars/localhost to fix sudo on Semaphore runner delegate_to: localhost tasks inherit the Semaphore host's system ansible.cfg which has become=True. An explicit localhost inventory entry with ansible_become: false overrides this at inventory precedence level. Co-Authored-By: Claude Sonnet 4.6 --- host_vars/localhost.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 host_vars/localhost.yml diff --git a/host_vars/localhost.yml b/host_vars/localhost.yml new file mode 100644 index 0000000..8d554ac --- /dev/null +++ b/host_vars/localhost.yml @@ -0,0 +1,5 @@ +# Connection settings for localhost (used by delegate_to: localhost tasks +# and the report generation play that runs on the Semaphore runner itself). +# Explicit settings here override any system-wide ansible.cfg become=True. +ansible_connection: local +ansible_become: false