compress merged logs under /var/log/hosts

This commit is contained in:
Seddik Alaoui Ismaili 2023-06-13 14:02:57 +02:00 committed by kevin
parent 14eb1bc04e
commit b79003cfda
3 changed files with 6 additions and 0 deletions

View file

@ -0,0 +1 @@
0 06 * * * root /usr/bin/find /var/log/hosts -type f -name "*.log" -print | grep -v "$(date +'/%Y/%m/%d/')" | xargs -n1 xz -1 > /dev/null

View file

@ -504,5 +504,10 @@
- config
- python3alternative
- name: daily cron job to compress merged log under /var/log/hosts
copy: src=compress-log.cron dest=/etc/cron.d/ mode=0644
tags:
- compress
- name: Set crypto-policy to LEGACY on fedora 33 hosts to get 2fa working
import_tasks: crypto-policies.yml