Initial version of ldap module.
This commit is contained in:
parent
fa2eef5391
commit
082b88cc0d
2 changed files with 35 additions and 0 deletions
25
ldap/manifests/init.pp
Normal file
25
ldap/manifests/init.pp
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
|
||||||
|
|
||||||
|
class ldap::client {
|
||||||
|
|
||||||
|
package { "openldap-client":
|
||||||
|
name => $operatingsystem ? {
|
||||||
|
openbsd => "openldap-client",
|
||||||
|
default => "openldap-clients",
|
||||||
|
},
|
||||||
|
ensure => installed,
|
||||||
|
}
|
||||||
|
|
||||||
|
file { "/etc/openldap/ldap.conf":
|
||||||
|
ensure => present,
|
||||||
|
content => template("ldap/ldap.conf.erb"),
|
||||||
|
mode => 0644,
|
||||||
|
owner => root,
|
||||||
|
group => $operatingsystem ? {
|
||||||
|
openbsd => wheel,
|
||||||
|
default => root,
|
||||||
|
},
|
||||||
|
require => Package["openldap-client"],
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
10
ldap/templates/ldap.conf.erb
Normal file
10
ldap/templates/ldap.conf.erb
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
#
|
||||||
|
# LDAP Defaults
|
||||||
|
#
|
||||||
|
|
||||||
|
# See ldap.conf(5) for details
|
||||||
|
# This file should be world readable but not world writable.
|
||||||
|
|
||||||
|
BASE <%= ldap_basedn %>
|
||||||
|
URI <% ldap_server.each do |uri| %><%= uri %> <% end %>
|
||||||
|
TLS_REQCERT allow
|
Loading…
Add table
Reference in a new issue