Skip to content

set static group and user for every mailbox#8

Open
edoput wants to merge 7 commits into
mailfrom
static_group_user_dovecot
Open

set static group and user for every mailbox#8
edoput wants to merge 7 commits into
mailfrom
static_group_user_dovecot

Conversation

@edoput

@edoput edoput commented Jun 6, 2016

Copy link
Copy Markdown
Member

This should solve the issue with multiple maildirs

@edoput
edoput force-pushed the static_group_user_dovecot branch from 4085af3 to 3a46f6b Compare June 8, 2016 16:40
@cimbalo

cimbalo commented Jun 8, 2016

Copy link
Copy Markdown
Contributor

It doesn't work.
From /var/log/mail.log:

Jun 8 23:28:27 mail dovecot: lda(test_user@lilik.it): Fatal: setgid(100(users) from userdb lookup) failed with euid=800(postman), gid=800(postman), egid=800(postman): Operation not permitted (This binary should probably be called with process group set to 100(users) instead of 800(postman))

@cimbalo

cimbalo commented Jun 8, 2016

Copy link
Copy Markdown
Contributor

@05bdea85cea918cd06a295e259c563ce356c29a7
Override an entire file (/etc/dovecot/dovecot.conf) only to add two lines is not a good practice, since it cause the loss of all the configuration change from the package maintainers.

@edoput
edoput force-pushed the static_group_user_dovecot branch from 05bdea8 to 24f0723 Compare June 8, 2016 22:34
@edoput

edoput commented Jun 9, 2016

Copy link
Copy Markdown
Member Author

schermata da 2016-06-09 10 58 16

it's working

@edoput
edoput force-pushed the static_group_user_dovecot branch from ccde826 to 0b00384 Compare June 9, 2016 09:10
@cimbalo

cimbalo commented Jun 9, 2016

Copy link
Copy Markdown
Contributor

@0b003846875200cec746f746c89ca82ca0ee236e
homeDirectory and vdhome are either ldap attributes and none of them is a valid dovecot userdb attribute.

If this line is only a trick to disable default users_attrs query I suggest something more self explaining.

Funny fact
this query works fine too (tested!)

users_attrs = pippo=pippopippo #(I hope you enjoy the reference)

@edoput

edoput commented Jun 10, 2016

Copy link
Copy Markdown
Member Author
user_attrs = homeDirectory=home,uidNumber=uid,gidNumber=gid
# or if you're using global UID and GID:
user_attrs = homeDirectory=home

that was on the ldap configuration on the wiki, guess it's outdated too.

Why aren't we using a static userdb? It seems that it's the best choice

Since dovecot-lda looks up the user only from the userdb, it of course doesn't work with static userdb because there is no list of users. Normally static userdb handles this by doing a passdb lookup instead. This works with most passdbs...

We could get rid of this insane back and forth with LDAP users database

@cimbalo
cimbalo force-pushed the mail branch 2 times, most recently from 7721159 to 5e0d924 Compare August 17, 2016 01:38
@edoput
edoput force-pushed the static_group_user_dovecot branch from c74a10a to 53bd759 Compare August 17, 2016 15:31
@edoput
edoput force-pushed the static_group_user_dovecot branch from 53bd759 to 11a3953 Compare August 17, 2016 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants