Add cron jobs to clean cached Mastodon data, close #170

This commit is contained in:
Sam A. 2023-07-11 21:56:04 +02:00
parent 9920676155
commit 7d8b96cef0
Signed by untrusted user: samsapti
GPG Key ID: CBBBE7371E81C4EA
1 changed files with 18 additions and 0 deletions

View File

@ -187,3 +187,21 @@
external: true
internal_network:
internal: true
- name: Configure cron job to remove old Mastodon media daily
cron:
name: Clean Mastodon media data older than a week
cron_file: ansible_mastodon_clean_media
job: docker exec mastodon_web_1 tootctl media remove --days 7
special_time: daily
user: root
state: present
- name: Configure cron job to remove old Mastodon preview cards daily
cron:
name: Clean Mastodon media data older than a week
cron_file: ansible_mastodon_clean_preview_cards
job: docker exec mastodon_web_1 tootctl media remove --days 14
special_time: daily
user: root
state: present