Public Repository

Last pushed: 2 years ago
Short Description
Alpine Image with a compiled version of nginx to have LDAP authentication plugin enabled
Full Description

This is nginx 1.9.15 with the ldap plugin enabled.

To use this image

docker run -v <pathto>/nginx.conf:/etc/nginx/nginx.conf -p 80:80 -p 443:443 chingmd/nginx-ldap-auth-alpine

You will need to include the following into your nginx conf to configure the ldap plugin

 auth_ldap_cache_enabled on;
  auth_ldap_cache_expiration_time 10000;
  auth_ldap_cache_size 1000;
  ldap_server LDAP1 {
      # The following line help limit the search results.  Change to match your ldap.  
      url "ldaps://<HOSTOFLDAPSERVER>636/<LDAP SERACH PATH>?uid?sub?(objectClass=inetOrgPerson)";
      binddn "<DN of user to binddn>";
      binddn_passwd "****************";
      group_attribute member;
      group_attribute_is_dn on;
      connect_timeout 5s;
      bind_timeout 5s;
      request_timeout 5s;
      satisfy all;
      require group "<DN of group to filter on>";

In the server/location section of your configuration, you'll need to add:

   auth_ldap "Please authenticate yourself";
   auth_ldap_servers LDAP1;
Docker Pull Command