Puppet Class: samplicator

Defined in:
modules/samplicator/manifests/init.pp

Overview

Parameters:

  • targets (Array[String])
  • port (Stdlib::Port) (defaults to: 2000)
  • recvbuf (Integer) (defaults to: *)


15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'modules/samplicator/manifests/init.pp', line 15

class samplicator(
  Array[String] $targets,
  Stdlib::Port $port = 2000,
  Integer $recvbuf = 50*1024*1024,
  ) {

    ensure_packages('samplicator')

    systemd::service { 'samplicator':
        content        => template('samplicator/samplicator.service.erb'),
        require        => Package['samplicator'],
        restart        => true,
        service_params => {
            ensure     => 'running', # lint:ignore:ensure_first_param
        },
    }

    profile::auto_restarts::service { 'samplicator': }

    nrpe::monitor_service { 'samplicator-process':
        ensure       => absent,
        description  => 'Samplicator process',
        nrpe_command => '/usr/lib/nagios/plugins/check_procs -c 1:1 -C samplicate',
        notes_url    => 'https://wikitech.wikimedia.org/wiki/Netflow#Process',
    }
  }