HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Tips/Tricks/Mods (http://www.howtoforge.com/forums/forumdisplay.php?f=29)
-   -   ISPConfig + Roundcube sieverules-plugin = ISP_sieverules (http://www.howtoforge.com/forums/showthread.php?t=53924)

osterhase 26th August 2011 19:27

ISPConfig + Roundcube sieverules-plugin = ISP_sieverules
 
1 Attachment(s)
Hi there!

When switching our servers to ISPConfig we had the problem that we already had a roundcube installations up & running and we wanted to keep the roundcube-plugin sieverules because it allows the user to edit his filter-settings from within the webmailer in a quite comfortable manner.

With the help of the sieverules-plugin-developer (roundcube-team) we wrote a plugin which utilizes the api-functions of ispconfig to establish the communication between roundcube and ISPConfig. Because it was quite a hard struggle we don't want that anybody else has to fight this again. ;)

Basically from the repo-version of the sieverules-plugin for roundcube 0.6beta onwards a hook was implemented by John_Doe which is utilized by the plugin (we managed to get it also run with rouncube 0.5 stable). ISP-sieverules contacts to ispconfig via the api-interfaces and makes a mail_user update. The sieve-script is written into the custom-rules field in the ispconfig mail_user table and then implemented into the sieve-file.

Requirements:
Dovecot (with sieve plugin)
Roundcube 0.6beta (also possible with Roundcube 0.5 stable)
Sieverules-Plugin (current repo-version contains the hook)

Installation-Instruction:
- Download the plugin unzip and put in your roundcube-plugin directory (add the plugin in your main-config file)
- Create a remote user for ISPConfig in the Adminstration-Panel
- Recommended: Create a database-user for the ispdatabase which may only use the SELECT statement
- configure the plugin via the config.inc.php (contained in the zip-file)

Have fun! ;)

Horfic 26th August 2011 21:40

1 Attachment(s)
Well done, except that the db function just to get the mailuser_id is stupid.

Use the api for that.

Its very simple.

I included as attachment the updated files.

osterhase 29th August 2011 11:32

1 Attachment(s)
Hey Horfic,

thanks for the optimization of the plugin! I corrected a little mistake which made the plugin not runable and removed a not longer necesarry line from the config-file.

Furthermore I was informed that the name of the hook that was implemented in the sieverules-plugin is no longer "sieverules_saved" but "sieverules_save" - so I changed that one as well.

The install instructions are getting easier due to Horfics changes because the (little bit weird) db function rendered unnecessary:
- Download the plugin unzip and put in your roundcube-plugin directory (add the plugin in your main-config file)
- Create a remote user for ISPConfig in the Adminstration-Panel
- configure the plugin via the config.inc.php (contained in the zip-file)

Have fun out there!

osterhase 30th August 2011 10:52

Hi there!

Maybe someone can give me a hand here: Due to the fact that the sieverules-plugin of roundcube allows more complex filtering solutions than ISPConfig we found the require-line which is written by ispconfig insufficient:

Code:

require ["fileinto", "regex", "vacation"];
Because some of our users are utilizing the copy-function for instance the require line would read:

Code:

require ["fileinto","regex","vacation","copy"];
As far as I'm concerned the require line is written statically to the dovecot.sieve-file. In which file is this directive defined so we can simply add more sieve-filter-features?

cusco 6th November 2011 18:38

how ?
 
hi,

Im trying to enable this solution, however sieverules plugin errors me out because there is no service listening in port 2000 at localhost

I enabled both isp_sieverules and sieverules.. what am I doing wrong?

osterhase 8th November 2011 18:11

Heya,

sorry for the delay.

Two options:
a) Your managesieve-daemon is not running (did you install the sieve-plugin for dovecot properly? See requirements above.)

b) Your manage-sieve daemon is not listening on the default port (2000). This should be configured in /etc/dovecot/dovecot.conf

For further informations, see:
http://wiki.dovecot.org/ManageSieve/Configuration

Best regards
osterhase


All times are GMT +2. The time now is 22:33.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.