Puppet Class: snapshot::cron::wikidatadumps::json

Defined in:
modules/snapshot/manifests/cron/wikidatadumps/json.pp

Overview

Parameters:

  • user (Any) (defaults to: undef)
  • filesonly (Any) (defaults to: false)


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

class snapshot::cron::wikidatadumps::json(
    $user      = undef,
    $filesonly = false,
) {
    $scriptpath = '/usr/local/bin/dumpwikidatajson.sh'
    file { $scriptpath:
        mode    => '0755',
        owner   => 'root',
        group   => 'root',
        source  => 'puppet:///modules/snapshot/cron/dumpwikidatajson.sh',
        require => Class['snapshot::cron::wikidatadumps::common'],
    }

    if !$filesonly {
        cron { 'wikidatajson-dump':
            ensure      => 'present',
            command     => $scriptpath,
            environment => 'MAILTO=ops-dumps@wikimedia.org',
            user        => $user,
            minute      => '15',
            hour        => '3',
            weekday     => '1',
            require     => File[$scriptpath],
        }
    }
}