+ unless empty($slack) {
+ file { "$base_installation::puppet_conf_path/slack.yaml":
+ content => template("base_installation/puppet/slack.yaml.erb"),
+ require => File[$base_installation::puppet_conf_path],
+ }
+ }
+
+ if file("$base_installation::puppet_notifies_path/host_ldap.info", "/dev/null") != "" and
+ empty($facts["ldapvar"]) {
+ fail("LDAP was activated but facts are not available")
+ }
+
+ file { $base_installation::puppet_notifies_path:
+ ensure => directory,
+ require => [Package["puppet"], Package["gem:xmpp4r"], Package["gem:ruby-ldap"]],
+ recurse => true,
+ purge => true,
+ force => true,
+ }
+
+ $ips = lookup("ips", { 'default_value' => undef })
+ concat { "$base_installation::puppet_notifies_path/host_ldap.info":
+ ensure => "present",
+ mode => "0600",
+ require => File[$base_installation::puppet_notifies_path],
+ ensure_newline => true,
+ }
+
+ concat::fragment { "host_ldap add top":
+ target => "$base_installation::puppet_notifies_path/host_ldap.info",
+ content => template("base_installation/puppet/host_ldap_add_top.info.erb"),
+ order => "00-01",
+ }
+ concat::fragment { "host_ldap add bottom":
+ target => "$base_installation::puppet_notifies_path/host_ldap.info",
+ content => "EOF",
+ order => "00-99",
+ }
+
+ concat::fragment { "host_ldap mod top":
+ target => "$base_installation::puppet_notifies_path/host_ldap.info",
+ content => template("base_installation/puppet/host_ldap_mod_top.info.erb"),
+ order => "01-01",
+ }
+ concat::fragment { "host_ldap mod bottom":
+ target => "$base_installation::puppet_notifies_path/host_ldap.info",
+ content => "EOF",
+ order => "01-99",