wekan / ldap

LDAP support for Wekan code has been moved to https://github.com/wekan/wekan/tree/master/packages/wekan-ldap , issues to https://github.com/wekan/wekan/issues , and if PRs are needed please add them instead to https://github.com/wekan/wekan/pulls
https://github.com/wekan/wekan/tree/master/packages/wekan-ldap
MIT License
12 stars 10 forks source link

How to sync the email address in Wekan when the users has been import from LDAP with other mail #83

Open homero10 opened 4 years ago

homero10 commented 4 years ago

I have the issue with the LDAP sync mail.

The users, initially, not mail address asigned, and Wekan created the email using the LDAP_DEFAULT_DOMAIN in docker-compose file.

Now, for each users, from the LDAP server has been assigned an email adreess, but don't sync in Wekan.

This is my docker-compose file:

- LDAP_EMAIL_MATCH_ENABLE=true
  #
  # LDAP_EMAIL_MATCH_REQUIRE : require existing account matching by e-mail address when username does match
  - LDAP_EMAIL_MATCH_REQUIRE=true
  #
  # LDAP_EMAIL_MATCH_VERIFIED : require existing account email address to be verified for matching
  - LDAP_EMAIL_MATCH_VERIFIED=true
  #
  # LDAP_EMAIL_FIELD : which field contains the LDAP e-mail address
  - LDAP_EMAIL_FIELD=mail
  #-----------------------------------------------------------------
  - LDAP_SYNC_USER_DATA=true
  #
  - LDAP_SYNC_USER_DATA_FIELDMAP={"cn:name" , "mail":"email"}
  #

Any idea? Thanks

xet7 commented 4 years ago

You have extra spaces in fieldmap.

homero10 commented 4 years ago

I modified by - LDAP_SYNC_USER_DATA_FIELDMAP={"cn:"name","mail":"email"} but don't works

xet7 commented 4 years ago

@homero10

You should search previous open and closed issues and wiki about it, because someone has it working:

svenseeberg commented 4 years ago

I'm having the same issue. Has anyone found a documented solution?

*edit: sorry, my problem is different: users have an e-mail address synchronized when being created, but it does not update if changed in the LDAP source. But it could be the same reason, I guess.

I'm using the following configuration options:

LDAP_SYNC_USER_DATA_FIELDMAP={
         "mailPrimaryAddress": "email",
         "uid": "name"
}
LDAP_EMAIL_FIELD=mailPrimaryAddress
LDAP_SYNC_USER_DATA=true
svenseeberg commented 4 years ago

So I found that my issue was a not running sync. The sync interval values I entered (number in quotes) was not accepted. Now I see at least that it is doing something. However, in my case there are even more issues which I did not solve yet. The log prints [DEBUG] search filter "(|(=seebersv))" which seems broken to me. Not sure which setting to touch for this.

I guess a more detailed example with working values would be useful. I think I can share mine as soon as everything works as expected.