Commit f7042d9e authored by pedrolab's avatar pedrolab

Merge branch 'patch-1' into 'master'

Update README.md

See merge request !12
parents 342c3e5e 5fdf11b7
......@@ -478,20 +478,57 @@ Then import the file
ldapmodify -Y EXTERNAL -H ldapi:/// -f chg_admin_pass
## Delete members from a group using ldif
## Create a group using ldif
Edit `/tmp/add_group.ldif`
```
dn: cn=group_name,dc=example,dc=com
objectClass: top
objectClass: groupOfNames
cn: group_name
member: uid=existing_user,ou=users,dc=example,dc=com
```
Import configuration
ldapmodify -x -W -D "uid=my-user,dc=example,dc=com" -f /tmp/add_group.ldif
## Add a member from a group using ldif
Edit `/tmp/add_member.ldif`
```
dn: cn=group_name,dc=commonscloud,dc=coop
dn: cn=group_name,dc=example,dc=com
changetype: modify
add: member
member: uid=a_user,ou=users,dc=example,dc=com
```
Import configuration
ldapmodify -x -W -D "uid=my-user,dc=example,dc=com" -f /tmp/add_member.ldif
## Delete a member from a group using ldif
Edit `/tmp/delete_member.ldif`
```
dn: cn=group_name,dc=example,dc=com
changetype: modify
delete: member
member: uid=a_user,ou=users,dc=commonscloud,dc=coop
member: uid=a_user,ou=users,dc=example,dc=com
```
Import configuration
ldapmodify -x -W -D "uid=my-user,dc=commonscloud,dc=coop" -f /tmp/member_test.ldif
ldapmodify -x -W -D "uid=my-user,dc=commonscloud,dc=coop" -f /tmp/delete_member.ldif
# Apache Directory
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment