7.3. Webmail

For webmail we are going to install RoundCube. Download the latest version from their site and unapck it.

wget http://downloads.sourceforge.net/project/roundcubemail/roundcubemail/0.5.1/roundcubemail-0.5.1.tar.gz
tar -xvzf roundcubemail-0.5.1.tar.gz
mv roundcubemail-0.5.1 /var/www/roundcube

temp and logs folder need to be writable by the user that runs Apache (www-data).

chown www-data:www-data /var/www/roundcube/temp
chown www-data:www-data /var/www/roundcube/logs

Create MySQL tables and username:

mysql -p
CREATE DATABASE mail_roundcube;
CREATE USER 'roundcube'@'localhost' IDENTIFIED BY 'newpasswd';
GRANT ALL PRIVILEGES ON mail_roundcube.* TO 'roundcube'@'localhost';
FLUSH PRIVILEGES;
quit

Populate the database with tables:

mysql -p mail_roundcube < mysql.initial.sql

Point your browser to http://YOUR-IP-ADDRESS/roundcube/installer.

When prompted for configuration options enter select many identities with possibility to edit all params but not email address and select Use the current IMAP username and password for SMTP authentication. Fill in the database and other information requested.

[Note]Note

If you run into problems with suhosin.session.encrypt either chage the settings in /etc/php5/conf.d/suhosin.ini or uninstall php5-suhosin package.