Puppet Class: snapshot::dumps::timechecker

Defined in:
modules/snapshot/manifests/dumps/timechecker.pp

Overview

Parameters:

  • dumpsbasedir (Any) (defaults to: undef)
  • xmldumpsuser (Any) (defaults to: undef)


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# File 'modules/snapshot/manifests/dumps/timechecker.pp', line 1

class snapshot::dumps::timechecker(
    $dumpsbasedir = undef,
    $xmldumpsuser = undef,
)  {
    $repodir = $snapshot::dumps::dirs::repodir
    $wikis = ['arwiki', 'dewiki', 'commonswiki', 'frwiki', 'eswiki',
              'hewiki', 'huwiki', 'itwiki', 'jawiki', 'kowiki', 'metawiki',
              'nlwiki', 'plwiki', 'ptwiki', 'ruwiki', 'zhwiki',
              'enwiki', 'svwiki', 'ukwiki', 'viwiki', 'wikidatawiki']
    $wikis_list = join($wikis, ',')

    $apachedir = $snapshot::dumps::dirs::apachedir
    $dblist = "${apachedir}/dblists/all.dblist"

    cron { 'dumps-timechecker':
        ensure      => 'present',
        environment => 'MAILTO=ops-dumps@wikimedia.org',
        command     => "cd ${repodir}; python3 show_runtimes.py -d ${dumpsbasedir} -W ${wikis_list}; python3 show_runtimes.py -d ${dumpsbasedir} -j meta-history-bz2 -s 40 -w ${dblist}",
        user        => $xmldumpsuser,
        minute      => '10',
        hour        => '1',
        monthday    => [1, 20],
    }
}