Make glance cache management cron task idempotent

Use a seed in the glance cache management cron task's random
filter so that each host's results are idempotent when re-running.
This prevents the constant changing of the crontab whenever the
playbook is run.

Change-Id: Ia14e867347aeadc6c55cef49f9f2ae0e6f86412f
This commit is contained in:
Jimmy McCrory 2018-10-20 13:50:11 -07:00
parent a640cf037a
commit 2bb196613d
1 changed files with 1 additions and 1 deletions

View File

@ -109,7 +109,7 @@
- name: Create glance cache management cron jobs
cron:
name: "{{ item.name }}"
minute: "{{ 59 |random(start=1) }}"
minute: "{{ 59 | random(seed=inventory_hostname, start=1) }}"
day: "*"
hour: "{{ item.hour }}"
month: "*"