This file is indexed.

/usr/share/puppet/modules.available/puppetlabs-ntp/manifests/config.pp is in puppet-module-puppetlabs-ntp 7.1.1-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 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
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# @api private
# This class handles the configuration file. Avoid modifying private classes.
class ntp::config {

  #The servers-netconfig file overrides NTP config on SLES 12, interfering with our configuration.
  if ($facts['operatingsystem'] == 'SLES' and $facts['operatingsystemmajrelease'] == '12') or
    ($facts['operatingsystem'] == 'OpenSuSE' and $facts['operatingsystemmajrelease'] == '42') {
    file { '/var/run/ntp/servers-netconfig':
      ensure => 'absent'
    }
  }

  if $ntp::keys_enable {
    case $ntp::config_dir {
      '/', '/etc', undef: {}
      default: {
        file { $ntp::config_dir:
          ensure  => directory,
          owner   => 0,
          group   => 0,
          mode    => '0775',
          recurse => false,
        }
      }
    }

    file { $ntp::keys_file:
      ensure  => file,
      owner   => 0,
      group   => 0,
      mode    => '0600',
      content => epp('ntp/keys.epp'),
    }
  }

  #If both epp and erb are defined, throw validation error.
  #Otherwise use the defined erb/epp template, or use default
  if $ntp::config_epp and $ntp::config_template {
    fail('Cannot supply both config_epp and config_template templates for ntp config file.')
  } elsif $ntp::config_template {
    $config_content = template($ntp::config_template)
  } elsif $ntp::config_epp {
    $config_content = epp($ntp::config_epp)
  } else {
    $config_content = epp('ntp/ntp.conf.epp')
  }

  file { $ntp::config:
    ensure  => file,
    owner   => 0,
    group   => 0,
    mode    => $::ntp::config_file_mode,
    content => $config_content,
  }

  #If both epp and erb are defined, throw validation error.
  #Otherwise use the defined erb/epp template, or use default

  if $::ntp::step_tickers_file {
    if $::ntp::step_tickers_template and $::ntp::step_tickers_epp {
      fail('Cannot supply both step_tickers_file and step_tickers_epp templates for step ticker file')
    } elsif $::ntp::step_tickers_template {
      $step_ticker_content = template($ntp::step_tickers_template)
    } elsif $::ntp::step_tickers_epp {
      $step_ticker_content = epp($::ntp::step_tickers_epp)
    } else{
      $step_ticker_content = epp('ntp/step-tickers.epp')
    }

    file { $::ntp::step_tickers_file:
      ensure  => file,
      owner   => 0,
      group   => 0,
      mode    => $::ntp::config_file_mode,
      content => $step_ticker_content,
    }
  }

  if $ntp::logfile {
    file { $ntp::logfile:
      ensure => file,
      owner  => 'ntp',
      group  => 'ntp',
      mode   => '0664',
    }
  }

  if $ntp::disable_dhclient {
    augeas { 'disable ntp-servers in dhclient.conf':
      context => '/files/etc/dhcp/dhclient.conf',
      changes => 'rm request/*[.="ntp-servers"]',
    }

    file { '/var/lib/ntp/ntp.conf.dhcp':
      ensure => absent,
    }
  }
}