X-Git-Url: https://git.phdru.name/?a=blobdiff_plain;f=playbooks%2Fdebian%2Froles%2Finit-system%2Ftasks%2Fapt.yml;fp=playbooks%2Fdebian%2Froles%2Finit-system%2Ftasks%2Fapt.yml;h=a24e44aa49ae938a05a412da243cf1acd13cfc20;hb=34ee94071359b7e0e18c1365730fda2aff634fd5;hp=3ea63a8c2decd7aa7b9f02bbcf305832f301b8af;hpb=32c11aba66d9fc0cf3bf4efb38afccc300b546c7;p=ansible.git diff --git a/playbooks/debian/roles/init-system/tasks/apt.yml b/playbooks/debian/roles/init-system/tasks/apt.yml index 3ea63a8..a24e44a 100644 --- a/playbooks/debian/roles/init-system/tasks/apt.yml +++ b/playbooks/debian/roles/init-system/tasks/apt.yml @@ -1,3 +1,12 @@ +- 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: @@ -6,7 +15,7 @@ owner: root group: root mode: '0640' - force: no + when: apt_configured.stdout == "0" - name: Install minimal software packages become: true