Univention Bugzilla – Bug 41601
add user to certain groups, when adding it to another school
Last modified: 2016-10-06 08:53:54 CEST
When a User (staff, student, teacher, teacherandstaff, administartor?) is added (not moved) to an additional school, it must also be added to the group "Domain Users <ou>" as well as the respective schueler-<ou>, staff-<ou> etc.
*** Bug 41643 has been marked as a duplicate of this bug. ***
ucs-school-lib (9.0.20-5): r70565 | Bug #41601: add user to groups groups of all schools where he is member of ucs-school-lib.yaml: r70566 | YAML Bug #41601
*** Bug 41640 has been marked as a duplicate of this bug. ***
OK: Code changes OK: advisory (changed wording r70761) OK: manual test: astudent1 = Student(name="astudent1", firstname="fn1", lastname="ln1", school="schule1", school_classes={"schule1": ["schule1-1A"]}) astudent1.create(lo) → True astudent1 = Student.from_dn(astudent1.dn, astudent1.school, lo) print("school: {}\nschools: {}\nschool_classes: {}\ngroups_used: {}".format( astudent1.school, astudent1.schools, astudent1.school_classes, astudent1.groups_used(lo))) → school: schule1 → schools: ['schule1'] → school_classes: {'schule1': ['schule1-1A']} → groups_used: ['cn=Domain Users schule1,cn=groups,ou=schule1,dc=uni,dc=dtr', 'cn=schule1-1A,cn=klassen,cn=schueler,cn=groups,ou=schule1,dc=uni,dc=dtr', 'cn=schueler-schule1,cn=groups,ou=schule1,dc=uni,dc=dtr'] astudent1.schools.append("schule2") astudent1.modify(lo) → True print("school: {}\nschools: {}\nschool_classes: {}\ngroups_used: {}".format( astudent1.school, astudent1.schools, astudent1.school_classes, astudent1.groups_used(lo))) → school: schule1 → schools: ['schule1', 'schule2'] → school_classes: {'schule1': ['schule1-1A']} → groups_used: ['cn=Domain Users schule1,cn=groups,ou=schule1,dc=uni,dc=dtr', 'cn=Domain Users schule2,cn=groups,ou=schule2,dc=uni,dc=dtr', 'cn=schule1-1A,cn=klassen,cn=schueler,cn=groups,ou=schule1,dc=uni,dc=dtr', 'cn=schueler-schule1,cn=groups,ou=schule1,dc=uni,dc=dtr', 'cn=schueler-schule2,cn=groups,ou=schule2,dc=uni,dc=dtr']
A test for this is in 90_ucsschool/80_move_users_into_another_ou.
UCS@school 4.1 R2 v5 has been released. http://docs.software-univention.de/changelog-ucsschool-4.1R2v5-de.html If this error occurs again, please clone this bug.