Skip to content

Commit

Permalink
testing ldap dir
Browse files Browse the repository at this point in the history
  • Loading branch information
djentangle committed Aug 1, 2024
1 parent 7879af8 commit 5c5fbd9
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions test/cookbooks/openldap-test/recipes/accesslog.rb
Original file line number Diff line number Diff line change
@@ -1,24 +1,14 @@
ldap_dir =
case os.family
when 'debian'
'/etc/ldap'
when 'redhat', 'amazon', 'fedora', 'suse'
'/etc/openldap'
when 'bsd'
'/usr/local/etc/openldap'
end

node.default['openldap']['accesslog']['enabled'] = true
node.default['openldap']['accesslog']['logdb'] = '"cn=accesslog"'
node.default['openldap']['accesslog']['directory'] = "#{ldap_dir}/accesslog"
node.default['openldap']['accesslog']['directory'] = "/etc/ldap/accesslog"
node.default['openldap']['accesslog']['index'] = 'reqStart,reqEnd,reqResult eq'
node.default['openldap']['accesslog']['logops'] = 'writes'
node.default['openldap']['accesslog']['logold'] = '(objectclass=*)'
node.default['openldap']['accesslog']['logpurge'] = '8+00:00 1+00:00'

node.default['openldap']['modules'] << 'accesslog'

directory "#{ldap_dir}/accesslog" do
directory "/etc/ldap/accesslog" do
mode '0755'
owner 'openldap'
group 'openldap'
Expand Down

0 comments on commit 5c5fbd9

Please sign in to comment.