General developer forum

Getting enrol_ldap to automatically create user if user exists on LDAP but not in moodle.mdl_user

 
Picture of Mark Farnell
Getting enrol_ldap to automatically create user if user exists on LDAP but not in moodle.mdl_user
 

I am using moodle 3.3, with Shibboleth authentication (auth_shibboleth), and LDAP enrolment (enrol_ldap)


I set up enrol_ldap so that it does not automatically create courses.  However, if a course "foo" in moodle.mdl_course with idnumber matching the cn of a course on the LDAP server, then enrol_ldap will update the course "foo", and add users listed in course "foo" on the LDAP server who are not already listed in course "foo" in moodle into the course "foo" in moodle.

However, if a user X listed in course "foo" on the LDAP server is not already in the moodle.mdl_user table, then how can I get enrol_ldap to automatically add that user X to moodle.mdl_user, and enrol user X into course "foo" in moodle?

If this is not currently possible, I strongly believe that automatically creating a user should be an option in enrol_ldap, as not every moodle installation using enrol_ldap also use auth_ldap.



 
Average of ratings: -
Picture of Richard Oelmann
Re: Getting enrol_ldap to automatically create user if user exists on LDAP but not in moodle.mdl_user
 
Average of ratings: -