def service
      return nil if config[:enabled] == false
      if @ldap_service.nil?
        @ldap_service = Net::LDAP.new(host: config[:host], auth: config[:auth])
        raise Net::LDAP::Error unless @ldap_service.bind
      end
      @ldap_service
    end
def service
      return nil if config[:enabled] == false
      if @ldap_service.nil?
        @ldap_service = Net::LDAP.new(host: config[:host], auth: config[:auth])
        raise Net::LDAP::Error unless @ldap_service.bind
      end
      @ldap_service
    end
Attempts to create a connection to LDAP and returns a cached Net::LDAP instance if successful.