From 670164494d3e9ff898ce6ea1ad552980ef863561 Mon Sep 17 00:00:00 2001 From: Bertrand Lanson Date: Mon, 27 Nov 2023 18:30:54 +0100 Subject: [PATCH] feat: add become to tasks to avoid relying on ansible.cfg --- tasks/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tasks/main.yml b/tasks/main.yml index ec72f81..fe70706 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -4,6 +4,7 @@ ansible.builtin.apt: update_cache: yes cache_valid_time: "{{ manage_apt_packages_apt_cache_time }}" + become: true - name: "Install/remove required apt packages" ansible.builtin.apt: @@ -14,3 +15,4 @@ when: manage_apt_packages_list is defined and manage_apt_packages_list not in [None, ''] notify: "apt-autoremove" + become: true