Alright, I am getting it now.
The way iRedMail manages domains is a bit strange - a little different from how I would do it without iRedMail.
Do I place all of my users under ou=Users, which is under my "main" domain, which is under o=Domains?
In normal environment, I create:
dc=localhost
--o=Example Inc.
----ou=People
------user
------user
------user
etc.
With iRedMail, I have
+--> dc=localhost (4)
---> cn=vmail
---> cn=vmailadmin
+--> o=domainAdmins (1)
| ---> mail=postmaster@mydomain.com
+--> o=domains (1)
| +--> domainName=mydomain.com (4)
| | ---> ou=Aliases
| | ---> ou=Externals
| | ---> ou=Groups
| | +--> ou=Users (2)
| | | ---> mail=neacys@mydomain.com
| | | ---> mail=www@mydomain.com
if mydomain.com is the only mail domain I will host on my server, then I can create all of my other users (which will use other services than iRedMail - jira, confluence, etc), then I can just add all of my users in ou=Users?
If I am to use LDAP for ALL accounts including iRedMail, users must use "mail" as prefix instead of UID or username?
Instead, could work if it was uid=neacys (instead of mail=neacys@mydomain.com)? neacys will be username for all services in network (neacys@mydomain.com) is only login for mail. For all other, just "neacys".
Also,
| | ---> ou=Aliases
| | ---> ou=Externals
| | ---> ou=Groups
I can erase these? Or needed for iRedMail?
EDIT: Is it correct to say that iRedMail auths(binds) via "email"?