Add a cronjob frequency to pypi_mirror

In order to call bandersnatch cronjob in a more
flexible way, depending on needs, add a setting to
configure the frequency in minutes.

Change-Id: Ia3fb7f5959075f77b6953a47d231aba780e38988
This commit is contained in:
Yolanda Robla 2015-03-10 15:04:39 +01:00
parent fa9e74d3b5
commit 914a043cfd

View File

@ -2,6 +2,7 @@
#
class openstack_project::pypi_mirror (
$vhost_name,
$cron_frequency = '*/5',
) {
include apache
@ -60,7 +61,7 @@ class openstack_project::pypi_mirror (
}
cron { 'bandersnatch':
minute => '*/5',
minute => $cron_frequency,
command => 'flock -n /var/run/bandersnatch/mirror.lock timeout -k 2m 30m run-bandersnatch >>/var/log/bandersnatch/mirror.log 2>&1',
environment => 'PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin',
}