Puppet Class: splunk::config::license

Defined in:
manifests/config/license.pp

Overview

Private Class to Configure Splunk License Slave

Parameters:

  • server (Any) (defaults to: undef)
  • SPLUNKHOME (Any) (defaults to: $::splunk::SPLUNKHOME)


2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'manifests/config/license.pp', line 2

class splunk::config::license (
  $server     = undef,
  $SPLUNKHOME = $::splunk::SPLUNKHOME
  ) {
  if ( $server == 'self' ) {
    $uri = $server
  } else {
    $uri = "https://${server}:8089"
  }
  if ( $server ) {
    ini_setting { 'Configure Splunk License':
      ensure  => present,
      path    => "${SPLUNKHOME}/etc/system/local/server.conf",
      section => 'license',
      setting => 'master_uri',
      value   => $uri,
      require => Class['splunk::install'],
      notify  => Class['splunk::service'],
    }
  }
}