]> git.phdru.name Git - ansible.git/commitdiff
Feat(init-system): Always update `/etc/apt/sources.list`
authorOleg Broytman <phd@phdru.name>
Mon, 19 Oct 2020 18:49:19 +0000 (21:49 +0300)
committerOleg Broytman <phd@phdru.name>
Mon, 19 Oct 2020 18:49:19 +0000 (21:49 +0300)
Module `template` doesn't overwrite identical file.

playbooks/roles/init-system/tasks/apt.yml

index 08340dcbc15bc896d4a04a8f75741253ddd3c2fe..7b2ee2ed1b8b1e785cff2fedde01aa429cb32b27 100644 (file)
@@ -1,12 +1,3 @@
-- name: Check backports
-  shell: "grep -Fc backports /etc/apt/sources.list || :"
-  register: apt_configured
-  changed_when: apt_configured.stdout == "0"
-
-- debug:
-    msg: "apt has already been configured"
-  when: apt_configured.stdout != "0"
-
 - name: Configure apt
   become: true
   template:
@@ -15,7 +6,6 @@
     owner: root
     group: root
     mode: '0640'
-  when: apt_configured.stdout == "0"
 
 - name: Install minimal software packages
   become: true