taskotron: install imagefactory-client cron jobs into /etc/cron.d
This commit is contained in:
parent
076ce8ea28
commit
ddc1e9c7d2
2 changed files with 12 additions and 10 deletions
roles/taskotron/imagefactory-client
|
@ -34,13 +34,10 @@
|
||||||
- name: Download/update images
|
- name: Download/update images
|
||||||
command: '/var/lib/fedoraqa/base_images/process_for_taskotron.py --taskotrondir {{imagesdir}}'
|
command: '/var/lib/fedoraqa/base_images/process_for_taskotron.py --taskotrondir {{imagesdir}}'
|
||||||
|
|
||||||
- name: Create cronjob to download new images
|
- name: Install cron job to download new ImageFactory images and clean up old ones
|
||||||
cron:
|
template:
|
||||||
name: "Download new images from ImageFactory"
|
src: imagefactory-client.cron.j2
|
||||||
special_time: hourly
|
dest: /etc/cron.d/imagefactory-client.cron
|
||||||
job: '/var/lib/fedoraqa/base_images/process_for_taskotron.py --taskotrondir {{imagesdir}} > /dev/null'
|
owner: root
|
||||||
- name: Create cronjob to prune old images
|
group: root
|
||||||
cron:
|
mode: 0644
|
||||||
name: "Clean up images downloaded from ImageFactory"
|
|
||||||
special_time: daily
|
|
||||||
job: '/var/lib/fedoraqa/base_images/prune_images/prune_images.py directory --keep 3 {{imagesdir}} > /dev/null'
|
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
# Download new images from ImageFactory
|
||||||
|
@hourly root /var/lib/fedoraqa/base_images/process_for_taskotron.py --taskotrondir {{imagesdir}} > /dev/null
|
||||||
|
|
||||||
|
# Clean up images downloaded from ImageFactory
|
||||||
|
@daily root /var/lib/fedoraqa/base_images/prune_images/prune_images.py directory --keep 3 {{imagesdir}} > /dev/null
|
Loading…
Add table
Add a link
Reference in a new issue