Puppet Class: confdroid_alloy::params

Summary

Class contains all parameters for the confdroid_alloy module.

Overview

confdroid_alloy::params.pp Module name: confdroid_alloy Author: 12ww1160 (12ww1160@confdroid.com)

Parameters:

  • ay_reqpackages (String) (defaults to: 'alloy')

    which packages to install

  • ay_pkg_ensure (String) (defaults to: 'latest')

    ‘latest’ or ‘present’

  • ay_loki_url (String) (defaults to: 'https://loki.example.net/loki/api/v1/push')

    the url where alloy will send logs to.

  • ay_loki_username (String) (defaults to: 'loki_user')

    the username to logon to loki

  • ay_loki_userpass (String) (defaults to: 'loki_pass')

    the password to logon to loki

  • ay_manage_loki (Boolean) (defaults to: true)

    whether to manage log forwarding to loki

  • ay_manage_prom (Boolean) (defaults to: true)

    whether to manage metric forwarding

  • ay_prom_url (String) (defaults to: 'https://prometheus.example.net/api/v1/write')

    the url where alloy will send metrics

  • ay_log_targets (Array) (defaults to: ['/var/log/messages','/var/log/secure',])

    the logging targets

  • ay_prom_honor_timestamps (Boolean) (defaults to: true)

    whether to honor timestamps in prometheus metrics

  • ay_prom_track_timestamps_staleness (Boolean) (defaults to: true)

    whether to track timestamps staleness in prometheus metrics

  • ay_prom_max_shards (String) (defaults to: '10')

    the maximum number of shards to use for prometheus metrics

  • ay_prom_max_samples_per_send (String) (defaults to: '2000')

    the maximum number of samples to send

  • ay_prom_batch_send_deadline (String) (defaults to: '5s')

    the maximum time to wait before sending

  • ay_manage_nagios (Boolean) (defaults to: false)

    whether to manage nagios service exports

  • ay_target_service (String) (defaults to: '/etc/nagios/conf.d/alloy_service.cfg')

    the target file for nagios service exports

  • ay_target_contacts (Array) (defaults to: ['nagiosadmin'])

    the contacts for nagios service exports



25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
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
# File 'manifests/params.pp', line 25

class confdroid_alloy::params (

  String $ay_reqpackages                      = 'alloy',
  String $ay_pkg_ensure                       = 'latest',

# loki
  Boolean $ay_manage_loki                     = true,
  String $ay_loki_url                         = 'https://loki.example.net/loki/api/v1/push',
  String $ay_loki_username                    = 'loki_user',
  String $ay_loki_userpass                    = 'loki_pass',
  Array $ay_log_targets                       = ['/var/log/messages','/var/log/secure',],

# prometheus
  Boolean $ay_manage_prom                     = true,
  String $ay_prom_url                         = 'https://prometheus.example.net/api/v1/write',
  Boolean $ay_prom_honor_timestamps           = true,
  Boolean $ay_prom_track_timestamps_staleness = true,
  String $ay_prom_max_shards                  = '10',
  String $ay_prom_max_samples_per_send        = '2000',
  String $ay_prom_batch_send_deadline         = '5s',

# nagios
  Boolean $ay_manage_nagios                   = false,
  String $ay_target_service                   = '/etc/nagios/conf.d/alloy_service.cfg',
  Array $ay_target_contacts                   = ['nagiosadmin'],

) {
  # defaults
  $fqdn               = $facts['networking']['fqdn']

  # service
  $ay_service         = 'alloy'

  # dirs
  $ay_main_dir        = '/etc/alloy'

  # files
  $ay_main_file       = "${ay_main_dir}/config.alloy"

  # includes must be last
  include confdroid_alloy::main::config
}