[Dovecot] AutoCreate per Domain
Hello,
is there a way to configure plugin "autocreate" per domain? Like:
For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech
Thanks.
Any idea?
On Thu, Jul 30, 2009 at 2:30 AM, Darvin Denmiandarvin.denmian@gmail.com wrote:
Hello,
is there a way to configure plugin "autocreate" per domain? Like:
For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech
Thanks.
Darvin Denmian schrieb:
Any idea?
On Thu, Jul 30, 2009 at 2:30 AM, Darvin Denmiandarvin.denmian@gmail.com wrote:
Hello,
is there a way to configure plugin "autocreate" per domain? Like:
For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech
Thanks.
i dont think this would be a good idea, cause there are so much layouts and setups thinkable so in fact it might be difficult to implement this for all thinkable cases in the plugin, in my maildrop setup i do some testing about folders exist, and if not create it, but deliver does not exec scripts right now i think
but perhaps you can exec test folder scripts at login stage
http://wiki.dovecot.org/PostLoginScripting
that should do the job
-- Best Regards
MfG Robert Schetterer
Germany/Munich/Bavaria
On Thu, 2009-07-30 at 02:30 -0300, Darvin Denmian wrote:
Hello,
is there a way to configure plugin "autocreate" per domain? Like:
For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech
You can return the autocreate-related settings from your userdb. Userdb extra fields can override any settings. http://wiki.dovecot.org/UserDatabase/ExtraFields
Hello,
unfortunaly I still don't have this working :(
Timo -> How I could apply your idea to solve my problem? Could you give me one more help with this "problem" ?
Thanks
On Thu, Jul 30, 2009 at 2:22 PM, Timo Sirainentss@iki.fi wrote:
On Thu, 2009-07-30 at 02:30 -0300, Darvin Denmian wrote:
Hello,
is there a way to configure plugin "autocreate" per domain? Like:
For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech
You can return the autocreate-related settings from your userdb. Userdb extra fields can override any settings. http://wiki.dovecot.org/UserDatabase/ExtraFields
Hello,
unfortunaly I still don't have this working :( Bellow what I was trying to use without sucess:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid , 'autocreate =
Clients' AS plugin, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'
Timo -> How I could apply your idea to solve my problem? Could you give me one more help with this "problem" ?
Thanks
On Aug 6, 2009, at 6:02 PM, Darvin Denmian wrote:
unfortunaly I still don't have this working :( Bellow what I was trying to use without sucess:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid , 'autocreate = Clients' AS plugin, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'
You need to return autocreate field containing the mailboxes you want
created. I guess you're trying to do:
user_query = select .., 'Clients' as autocreate, ..
Hello again,
God don't want that this solution work for me :(
I updated "user_query" to:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid ,
'Clients' AS autocreate, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'
And still don't work.
Thank Timo for your update
On Thu, Aug 6, 2009 at 7:06 PM, Timo Sirainentss@iki.fi wrote:
On Aug 6, 2009, at 6:02 PM, Darvin Denmian wrote:
unfortunaly I still don't have this working :( Bellow what I was trying to use without sucess:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid , 'autocreate = Clients' AS plugin, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'You need to return autocreate field containing the mailboxes you want created. I guess you're trying to do:
user_query = select .., 'Clients' as autocreate, ..
On Aug 6, 2009, at 6:34 PM, Darvin Denmian wrote:
Hello again,
God don't want that this solution work for me :(
I updated "user_query" to:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid ,
'Clients' AS autocreate, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'And still don't work.
You want "Clients" mailbox to be created, right? If you do:
Remove the autocreate from user_query and add "autocreate =
something" to plugin section. Does it get created?Add the autocreate back to user_query, keep autocreate=something in
plugin section. Does either one of them get created?
@dovecot.conf
mail_plugins = autocreate
plugin { autocreate = Clients1 }
@dovecot-sql.conf
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid ,
'Clients2' AS autocreate , mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'
Clients1 is sucessfuly created
Clients2 isn't created :(
Thanks TIMO !
Sorry for delay On Thu, Aug 6, 2009 at 8:44 PM, Timo Sirainentss@iki.fi wrote:
On Aug 6, 2009, at 6:34 PM, Darvin Denmian wrote:
Hello again,
God don't want that this solution work for me :(
I updated "user_query" to:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid ,
'Clients' AS autocreate, mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'And still don't work.
You want "Clients" mailbox to be created, right? If you do:
Remove the autocreate from user_query and add "autocreate = something" to plugin section. Does it get created?
Add the autocreate back to user_query, keep autocreate=something in plugin section. Does either one of them get created?
On Fri, 2009-08-07 at 14:49 -0300, Darvin Denmian wrote:
user_query = SELECT maildir, 1001 AS uid, 1001 AS gid ,
'Clients2' AS autocreate , mail_plugins
FROM mailbox WHERE username = '%u' AND active='1'Clients1 is sucessfuly created
Clients2 isn't created :(
Then it sounds like user_query isn't used at all. Show your dovecot -n output. Set auth_debug=yes and show what the logs say when you log in.
participants (3)
-
Darvin Denmian
-
Robert Schetterer
-
Timo Sirainen