From 7c2fdbd26802a5289320e0a02995be7f1d000b54 Mon Sep 17 00:00:00 2001 From: Ossi Salmi Date: Fri, 22 Oct 2010 23:33:01 +0300 Subject: [PATCH] Added support for Debian, Ubuntu and OS X to ldap::client. --- ldap/manifests/init.pp | 13 ++++++++++++- ldap/templates/ldap.conf.erb | 2 +- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/ldap/manifests/init.pp b/ldap/manifests/init.pp index f631bf8..6d9db18 100644 --- a/ldap/manifests/init.pp +++ b/ldap/manifests/init.pp @@ -16,18 +16,29 @@ class ldap::client { package { "openldap-client": name => $operatingsystem ? { + debian => "ldap-utils", + ubuntu => "ldap-utils", openbsd => "openldap-client", default => "openldap-clients", }, - ensure => installed, + ensure => $operatingsystem ? { + darwin => absent, + default => installed, + }, } file { "/etc/openldap/ldap.conf": ensure => present, content => template("ldap/ldap.conf.erb"), + path => $operatingsystem ? { + debian => "/etc/ldap/ldap.conf", + ubuntu => "/etc/ldap/ldap.conf", + default => "/etc/openldap/ldap.conf", + }, mode => 0644, owner => root, group => $operatingsystem ? { + darwin => wheel, openbsd => wheel, default => root, }, diff --git a/ldap/templates/ldap.conf.erb b/ldap/templates/ldap.conf.erb index b43acc7..79c7caa 100644 --- a/ldap/templates/ldap.conf.erb +++ b/ldap/templates/ldap.conf.erb @@ -7,4 +7,4 @@ BASE <%= ldap_basedn %> URI <% ldap_server.each do |uri| %><%= uri %> <% end %> -TLS_REQCERT allow +TLS_REQCERT never