From 26256017a206e720c94ff2661ee3b0865a7ed8c4 Mon Sep 17 00:00:00 2001 From: micafer Date: Wed, 14 Feb 2018 16:52:00 +0100 Subject: [PATCH] Fix #553 --- contextualization/basic.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/contextualization/basic.yml b/contextualization/basic.yml index 437ad88e5..8060eb0fa 100644 --- a/contextualization/basic.yml +++ b/contextualization/basic.yml @@ -47,7 +47,11 @@ when: ansible_distribution == "Ubuntu" ignore_errors: yes register: apt_update + become: yes + become_method: sudo - name: Ubuntu force apt update (avoid apt lock) command: apt update when: ansible_distribution == "Ubuntu" and apt_update|failed + become: yes + become_method: sudo