Puppet Class: psick::hosts::file
- Defined in:
- manifests/hosts/file.pp
Overview
This class manages the content of the /etc/hosts file
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'manifests/hosts/file.pp', line 10
class psick::hosts::file (
String $template = 'psick/hosts/file/hosts.erb',
Optional[Stdlib::IP::Address] $ipaddress = $psick::primary_ip,
Variant[Undef,String] $domain = $facts['networking']['domain'],
String $hostname = $facts['networking']['hostname'],
Array $extra_hosts = [],
Boolean $manage = $psick::manage,
Boolean $noop_manage = $psick::noop_manage,
Boolean $noop_value = $psick::noop_value,
) {
if $manage {
if $noop_manage {
noop($noop_value)
}
file { '/etc/hosts':
ensure => file,
content => template($template),
}
}
}
|