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)
  • wiki_file (Any) (defaults to: '/mnt/hdfs/wmf/refinery/current/static_data/mediawiki/grouped_wikis/grouped_wikis.csv')
  • input_directory_base (Any) (defaults to: '/mnt/data/xmldatadumps/public')
  • output_directory_base (Any) (defaults to: '/wmf/data/raw/mediawiki/dumps')
  • skip_list (Any) (defaults to: undef)
  • success_flag (Any) (defaults to: undef)
  • script_path (Any) (defaults to: "/usr/local/bin/${title}")
  • ensure (Any) (defaults to: 'present')


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
79
80
81
82
83
84
85
86
# File 'modules/profile/manifests/analytics/refinery/job/import_mediawiki_dumps_config.pp', line 50

define profile::analytics::refinery::job::import_mediawiki_dumps_config(
    $dump_type,
    $log_file_name,
    $timer_description,
    $timer_interval,
    $wiki_file = '/mnt/hdfs/wmf/refinery/current/static_data/mediawiki/grouped_wikis/grouped_wikis.csv',
    $input_directory_base = '/mnt/data/xmldatadumps/public',
    $output_directory_base = '/wmf/data/raw/mediawiki/dumps',
    $skip_list = undef,
    $success_flag = undef,
    $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',
        require     => File[$script_path],
    }

}