Defined Type: profile::analytics::refinery::job::import_mediawiki_dumps_config

Defined in:
modules/profile/manifests/analytics/refinery/job/import_mediawiki_dumps_config.pp

Overview

Parameters:

  • dump_type (Any)
  • log_file_name (Any)
  • timer_description (Any)
  • timer_interval (Any)
  • use_kerberos (Any)
  • wiki_file (Any) (defaults to: '/mnt/hdfs/wmf/refinery/current/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv')
  • input_directory_base (Any) (defaults to: '/mnt/data/xmldatadumps/public')
  • output_directory_base (Any) (defaults to: '/wmf/data/raw/mediawiki/dumps')
  • script_path (Any) (defaults to: "/usr/local/bin/${title}")
  • ensure (Any) (defaults to: 'present')


42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# File 'modules/profile/manifests/analytics/refinery/job/import_mediawiki_dumps_config.pp', line 42

define profile::analytics::refinery::job::import_mediawiki_dumps_config(
    $dump_type,
    $log_file_name,
    $timer_description,
    $timer_interval,
    $use_kerberos,
    $wiki_file = '/mnt/hdfs/wmf/refinery/current/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv',
    $input_directory_base = '/mnt/data/xmldatadumps/public',
    $output_directory_base = '/wmf/data/raw/mediawiki/dumps',
    $script_path = "/usr/local/bin/${title}",
    $ensure = 'present',
) {

    require ::profile::analytics::refinery

    $refinery_path = $profile::analytics::refinery::path
    $log_file      = "${profile::analytics::refinery::log_dir}/${log_file_name}"

    file { $script_path:
        ensure  => $ensure,
        content => template('profile/analytics/refinery/job/refinery-import-mediawiki-dumps.sh.erb'),
        mode    => '0550',
        owner   => 'analytics',
        group   => 'analytics',
    }

    kerberos::systemd_timer { $title:
        ensure       => $ensure,
        description  => $timer_description,
        command      => $script_path,
        interval     => $timer_interval,
        user         => 'analytics',
        use_kerberos => $use_kerberos,
        require      => File[$script_path],
    }

}