gitea: use random time for git gc run

Randomising the time of this job should help avoid a thundering herd
of I/O intensive operations in the gitea environment.

Change-Id: I035f7781a397665357b6d039b989ab9fe6a46b8a
This commit is contained in:
Ian Wienand 2019-09-04 05:15:21 +10:00
parent c9bea2cfc4
commit ace1c39c61

View File

@ -132,8 +132,8 @@
name: pack-git-refs
state: present
job: "docker exec -t giteadocker_gitea-web_1 find /data/git/repositories/ -maxdepth 2 -name *.git -type d -execdir git --git-dir={} gc --quiet \\;"
minute: 37
hour: 12
minute: '{{ 59 | random(seed=inventory_hostname) }}'
hour: '{{ 23 | random(seed=inventory_hostname) }}'
weekday: 0
- name: Create db backup dest
file: