Puppet Class: prometheus::node_varnishd_mmap_count

Defined in:
modules/prometheus/manifests/node_varnishd_mmap_count.pp

Overview

Parameters:

  • ensure (Wmflib::Ensure) (defaults to: 'present')
  • outfile (Pattern[/\.prom$/]) (defaults to: '/var/lib/prometheus/node.d/varnishd_mmap_count.prom')
  • service (Systemd::Servicename) (defaults to: 'varnish.service')


6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'modules/prometheus/manifests/node_varnishd_mmap_count.pp', line 6

class prometheus::node_varnishd_mmap_count (
    Wmflib::Ensure $ensure = 'present',
    Pattern[/\.prom$/] $outfile = '/var/lib/prometheus/node.d/varnishd_mmap_count.prom',
    Systemd::Servicename $service = 'varnish.service',
) {
    file { '/usr/local/bin/prometheus-varnishd_mmap_count':
        ensure => file,
        mode   => '0555',
        owner  => 'root',
        group  => 'root',
        source => 'puppet:///modules/prometheus/usr/local/bin/prometheus-varnishd_mmap_count',
    }

    # Collect every minute
    cron { 'prometheus_varnishd_mmap_count':
        ensure  => $ensure,
        user    => 'root',
        command => "/usr/local/bin/prometheus-varnishd_mmap_count ${service} ${outfile}",
    }
}