Puppet Class: dumps::generation::server::jobswatcher

Defined in:
modules/dumps/manifests/generation/server/jobswatcher.pp

Overview

Parameters:

  • dumpsbasedir (Any) (defaults to: undef)
  • locksbasedir (Any) (defaults to: undef)
  • user (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/dumps/manifests/generation/server/jobswatcher.pp', line 1

class dumps::generation::server::jobswatcher(
    $dumpsbasedir = undef,
    $locksbasedir = undef,
    $user         = undef,
)  {
    file { '/usr/local/bin/job_watcher.sh':
        ensure => 'present',
        mode   => '0755',
        owner  => 'root',
        group  => 'root',
        source => 'puppet:///modules/dumps/generation/job_watcher.sh',
    }

    systemd::timer::job { 'dump-jobs-watcher':
        ensure                  => 'present',
        description             => 'Watch for stalled XML dumps',
        environment             => {'MAILTO' => 'ops-dumps@wikimedia.org'},
        send_mail               => true,
        send_mail_only_on_error => false,
        command                 => "/bin/bash /usr/local/bin/job_watcher.sh --dumpsbasedir ${dumpsbasedir} --locksbasedir ${locksbasedir}",
        user                    => $user,
        interval                => {'start' => 'OnCalendar', 'interval' => '00/8:10'}
    }
}