tmpreaper: permit to switch back to ctime

This commit is contained in:
Andrea Dell'Amico 2022-12-23 17:48:53 +01:00
parent c00a4f62ae
commit 4507508a10
Signed by: adellam
GPG Key ID: 147ABE6CEB9E20FF
1 changed files with 8 additions and 1 deletions

View File

@ -11,10 +11,17 @@
- name: Change the date check criteria from ctime to mtime
ansible.builtin.lineinfile:
path: /etc/cron.daily/tmpreaper
regexp: '^ --ctime \\'
regexp: '^ --[c|m]time \\'
line: ' --mtime \'
when: not tmpreaper_use_ctime
- name: Change the date check criteria from ctime to mtime
ansible.builtin.lineinfile:
path: /etc/cron.daily/tmpreaper
regexp: '^ --[c|m]time \\'
line: ' --ctime \'
when: tmpreaper_use_ctime
- name: Install the tmpreaper configuration
ansible.builtin.template: src=tmpreaper.conf.j2 dest=/etc/tmpreaper.conf owner=root group=root mode=0444