diff options
author | Emil Renner Berthing <esmil@labitat.dk> | 2018-10-07 14:18:18 +0200 |
---|---|---|
committer | Emil Renner Berthing <esmil@labitat.dk> | 2018-10-07 14:28:22 +0200 |
commit | 812b86451fad7e116bd78ab635e4a04c1422c51c (patch) | |
tree | 8be633c0aa741ae927e1f48626fe438db100b213 /roles/raspbian | |
parent | 9a2c5e59f2f82a021879fa1d09d4d64c89ee914c (diff) | |
download | labitat-ansible-812b86451fad7e116bd78ab635e4a04c1422c51c.tar.gz labitat-ansible-812b86451fad7e116bd78ab635e4a04c1422c51c.tar.xz labitat-ansible-812b86451fad7e116bd78ab635e4a04c1422c51c.zip |
raspbian: apt: disable timers to save sd-card writes
Diffstat (limited to 'roles/raspbian')
-rw-r--r-- | roles/raspbian/tasks/apt.yml | 17 | ||||
-rw-r--r-- | roles/raspbian/tasks/main.yml | 2 |
2 files changed, 19 insertions, 0 deletions
diff --git a/roles/raspbian/tasks/apt.yml b/roles/raspbian/tasks/apt.yml new file mode 100644 index 0000000..6194bda --- /dev/null +++ b/roles/raspbian/tasks/apt.yml @@ -0,0 +1,17 @@ +--- +- name: Disable apt timers + systemd: + name: '{{ item }}' + enabled: no + with_items: + - apt-daily.timer + - apt-daily-upgrade.timer + when: not chroot +- name: '- when in chroot' + command: 'systemctl disable {{ item }}' + with_items: + - apt-daily.timer + - apt-daily-upgrade.timer + when: chroot + +# vim: set ts=2 sw=2 et: diff --git a/roles/raspbian/tasks/main.yml b/roles/raspbian/tasks/main.yml index 3200277..96fce1c 100644 --- a/roles/raspbian/tasks/main.yml +++ b/roles/raspbian/tasks/main.yml @@ -1,4 +1,6 @@ --- +- import_tasks: apt.yml + tags: apt - import_tasks: networkd.yml tags: networkd - import_tasks: remove_pi.yml |