Last change
on this file since 544 was
541,
checked in by sebas, 15 years ago
|
seperacion entre ubuntu y debian de los archivos de configuraciones
|
File size:
1.9 KB
|
Line | |
---|
1 | # |
---|
2 | # used like this: |
---|
3 | # |
---|
4 | # ldap_uri = 'ldap://ldap-server' |
---|
5 | # ldap_base = 'dc=example,dc=com' |
---|
6 | # ldap_ssl = 'true' |
---|
7 | # if ssl is not activated just don't put the line above. |
---|
8 | # include openldap::client |
---|
9 | |
---|
10 | class openldap::client { |
---|
11 | package { [ |
---|
12 | "base-files", |
---|
13 | "libnss-ldap", |
---|
14 | "libpam-ldap", |
---|
15 | "libpam-cracklib", |
---|
16 | "nscd" |
---|
17 | ]: ensure => installed |
---|
18 | } |
---|
19 | |
---|
20 | case $operatingsystem { |
---|
21 | Debian: { |
---|
22 | file { |
---|
23 | "/etc/pam_ldap.conf": |
---|
24 | require => Package["base-files"], |
---|
25 | ensure => present, |
---|
26 | content => template("openldap/pam_ldap.conf.erb"); |
---|
27 | "/etc/libnss-ldap.conf": |
---|
28 | require => Package["base-files"], |
---|
29 | ensure => present, |
---|
30 | content => template("openldap/ldap.conf.erb"); |
---|
31 | } |
---|
32 | } |
---|
33 | Ubuntu: { |
---|
34 | file { |
---|
35 | "/etc/ldap.conf": |
---|
36 | require => Package["base-files"], |
---|
37 | ensure => present, |
---|
38 | content => template("openldap/ldap.conf.erb"); |
---|
39 | "/etc/ldap/ldap.conf": |
---|
40 | require => Package["base-files"], |
---|
41 | ensure => present, |
---|
42 | content => template("openldap/ldap.conf.erb"); |
---|
43 | } |
---|
44 | } |
---|
45 | default: { |
---|
46 | err("Your $operatingsystem is not supported yet to configure openldap-client") |
---|
47 | } |
---|
48 | } |
---|
49 | |
---|
50 | file { |
---|
51 | "/etc/nsswitch.conf": |
---|
52 | source => "puppet:///openldap/etc/nsswitch.conf", |
---|
53 | ensure => present, |
---|
54 | require => Package["base-files"]; |
---|
55 | "/etc/pam.d": |
---|
56 | ensure => directory, |
---|
57 | mode => 644, |
---|
58 | owner => root, |
---|
59 | group => root, |
---|
60 | source => "puppet:///openldap/etc/pam.d/", |
---|
61 | recurse => "true", |
---|
62 | require => Package[base-files]; |
---|
63 | } |
---|
64 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.