Defined Type: wikistats::cronjob::update

Defined in:
modules/wikistats/manifests/cronjob/update.pp

Overview

define a cronjob to update a wikistats table usage: <project prefix>@<hour>

Parameters:

  • project (String) (defaults to: $name)
  • hour (Integer) (defaults to: 0)
  • minute (Integer) (defaults to: 0)
  • ensure (Wmflib::Ensure) (defaults to: 'present')


3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# File 'modules/wikistats/manifests/cronjob/update.pp', line 3

define wikistats::cronjob::update (
    String $project = $name,
    Integer $hour = 0,
    Integer $minute = 0,
    Wmflib::Ensure $ensure = 'present',
){

    cron { "cron-wikistats-update-${name}":
        ensure  => $ensure,
        command => "/usr/bin/php /usr/lib/wikistats/update.php ${project} > /var/log/wikistats/update_${name}.log 2>&1",
        user    => 'wikistatsuser',
        hour    => $hour,
        minute  => $minute,
    }
}