Puppet Class: simp_rsyslog::forward

Defined in:
manifests/forward.pp

Overview

NOTE: THIS IS A PRIVATE CLASS

Forward Rsyslog logs to remote servers

Parameters:

  • order (Integer) (defaults to: 99)

    The shell-glob-based ordering for the rule

  • dest_type (Enum['tcp','udp','relp']) (defaults to: 'tcp')

    The protocol to use when forwarding to the remote log server

    • If you use tcp then you will need to adjust the TLS settings via parameters in the ::rsyslog class directly.

  • stop_processing (Boolean) (defaults to: false)

    Do not continue processing additional Rsyslog rules after the logs have been sent to the remote server.

    • In general, you will not want to have this set since you will not have any of the matching logs written to local disk. However, this may be appropriate for ephemeral systems, systems with very slow disks, or systems where you want a minimum of log information to be captured locally.

Author:



26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# File 'manifests/forward.pp', line 26

class simp_rsyslog::forward (
  Integer                  $order           = 99,
  Enum['tcp','udp','relp'] $dest_type       = 'tcp',
  Boolean                  $stop_processing = false
){
  assert_private()

  if empty($::simp_rsyslog::log_servers) {
    fail('You must specify $::simp_rsyslog::log_servers when attempting to forward logs')
  }

  rsyslog::rule::remote { "${order}_simp_rsyslog_profile_remote":
    rule                 => $::simp_rsyslog::security_relevant_logs,
    dest                 => $::simp_rsyslog::log_servers,
    failover_log_servers => $::simp_rsyslog::failover_log_servers,
    dest_type            => $dest_type,
    stop_processing      => $stop_processing
  }
}