Defined Type: prometheus::blazegraph_exporter

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

Overview

Parameters:

  • blazegraph_port (Any)
  • prometheus_port (Any)
  • prometheus_nodes (Any)


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/prometheus/manifests/blazegraph_exporter.pp', line 1

define prometheus::blazegraph_exporter (
    $blazegraph_port,
    $prometheus_port,
    $prometheus_nodes,
) {
    $prometheus_ferm_nodes = join($prometheus_nodes, ' ')
    $ferm_srange = "(@resolve((${prometheus_ferm_nodes})) @resolve((${prometheus_ferm_nodes}), AAAA))"

    systemd::service { "prometheus-blazegraph-exporter-${title}":
        ensure         => present,
        content        => systemd_template('prometheus-blazegraph-exporter'),
        restart        => true,
        require        => File['/usr/local/bin/prometheus-blazegraph-exporter'],
        service_params => {
            ensure => 'running',
        }
    }

    ferm::service { "prometheus-blazegraph-exporter-${title}":
        proto  => 'tcp',
        port   => $prometheus_port,
        srange => $ferm_srange,
    }

    base::service_auto_restart { "prometheus-blazegraph-exporter-${title}": }
}