user_ldap icon indicating copy to clipboard operation
user_ldap copied to clipboard

occ user:sync does not work for one user only

Open dpakach opened this issue 4 years ago • 2 comments

Description

When we do occ user:sync "OCA\User_LDAP\User_Proxy" then this syncs all the users from the LDAP server. Running occ user:sync "OCA\User_LDAP\User_Proxy" -u <uid> should only sync user with id <uid>.

Steps

  1. Setup LDAP server and add to owncloud.
  2. Add users to the LDAP server (for eg. user1 and user2)
  3. run occ user:sync "OCA\User_LDAP\User_Proxy" to sync all the users
  4. Modify an attribute on the LDAP server for user1 (eg Display Name).
  5. run occ user:sync "OCA\User_LDAP\User_Proxy" -u user1 to sync just for user1

Expected Behavior

The displayName attribute of the user gets updated in owncloud.

Actual Behavior

We get following output

➜ sudo -u www-data php occ user:sync "OCA\User_LDAP\User_Proxy" -u user1

If unknown users are found, what do you want to do with their accounts? (removing the account will also remove its data)
  [0] disable
  [1] remove
  [2] ask later
 > 0
Syncing user1 ...
Disabling accounts:
user1, User Onessss, [email protected] disabled

And the attribute of the user doesn't get changed.

dpakach avatar Oct 17 '19 07:10 dpakach