From c42f9ae1f9c66e1dcdd498dd9b3dc1bb3c72cf6d Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Mon, 24 Jun 2024 21:38:31 +0200 Subject: [PATCH] Set become_flags in ansible.cfg MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Some users don’t have a login shell. --- ansible.cfg | 1 + roles/forgejo/tasks/main.yml | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible.cfg b/ansible.cfg index b9a76ef..d315089 100644 --- a/ansible.cfg +++ b/ansible.cfg @@ -5,3 +5,4 @@ remote_user = root [privilege_escalation] become_method = su +become_flags = -s /bin/sh -l diff --git a/roles/forgejo/tasks/main.yml b/roles/forgejo/tasks/main.yml index 269aca4..77f23c5 100644 --- a/roles/forgejo/tasks/main.yml +++ b/roles/forgejo/tasks/main.yml @@ -142,7 +142,6 @@ - name: Register runner become: yes become_user: forgejo-runner - become_flags: '-s /bin/sh -l' command: | forgejo-runner register --no-interactive --name runner --instance https://git.fri.uni-lj.si