Autocreate plugin
=================

Comes with v1.2.alpha3+.

This plugin allows administrator to specify mailboxes that must always exist
for all users. They can optionally also be subscribed. The mailboxes are
created and subscribed always after user logs in. Namespaces are fully
supported, so namespace prefixes need to be used where necessary.

Example:

---%<-------------------------------------------------------------------------
protocol imap {
  mail_plugins = autocreate
}
plugin {
  autocreate = Trash
  autocreate2 = Spam
  #autocreate3 = ..etc..
  autosubscribe = Trash
  autosubscribe2 = Spam
  #autosubscribe3 = ..etc..
}
---%<-------------------------------------------------------------------------

v1.1
----

The plugin is also available from
http://www.dovecot.org/patches/1.1/autocreate-plugin.c. To compile the plugin
by hand, do the following:

---%<-------------------------------------------------------------------------
# replace * with the correct version:
export DOVECOT=~/src/dovecot-1.1.*

gcc -fPIC -shared -g -Wall -I$DOVECOT -I$DOVECOT/src/lib \
-I$DOVECOT/src/lib-storage -I$DOVECOT/src/lib-mail \
 -I$DOVECOT/src/lib-imap -DHAVE_CONFIG_H \
autocreate-plugin.c -o autocreate_plugin.so

# $PREFIX is the installation directory, e.g. /usr/local or /usr:
cp autocreate_plugin.so $PREFIX/lib/dovecot/imap/autocreate_plugin.so
---%<-------------------------------------------------------------------------

The plugin does not need a lib_xy prefix. 

(This file was created from the wiki on 2009-01-07 04:42)
