This shows you the differences between two versions of the page.
build:webmail [2008/02/21 10:56] 24.216.65.43 Created to list potential webmail apps. (CMB) |
build:webmail [2011/05/21 15:11] SLUUG Administration |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== WebMail ====== | + | ====== Webmail ====== |
- | Potential webmail apps: | + | We chose [[http://roundcube.net | RoundCube]] after trying a bunch of other webmail applications. Here are some that we tried: |
+ | |||
+ | * Bongo (formerly Hula) - could not get it to install | ||
+ | * SquirrelMail - old UI is hard to work with | ||
+ | * Horde (IMP) - complicated setup, does too much | ||
+ | * Zimbra - too integrated with email servers | ||
+ | |||
+ | ===== Installation ===== | ||
+ | |||
+ | First, install the prerequisites (and their dependencies): | ||
+ | |||
+ | <code bash> | ||
+ | sudo yum install -y php53-gd php53-intl php53-mbstring php53-xml | ||
+ | </code> | ||
+ | |||
+ | Next, create the directory to store the program in: | ||
+ | |||
+ | <code bash> | ||
+ | SITE=webmail.sluug.org | ||
+ | APACHE_USER=apache | ||
+ | sudo mkdir /srv/www/$SITE | ||
+ | sudo chown -R $APACHE_USER:$APACHE_USER /srv/www/$SITE | ||
+ | sudo chmod g+s /srv/www/$SITE | ||
+ | </code> | ||
+ | |||
+ | Get the latest version of the RoundCube code from the Subversion repository: | ||
+ | |||
+ | <code bash> | ||
+ | cd /srv/www/$SITE | ||
+ | sudo svn checkout --trust-server-cert --non-interactive https://svn.roundcube.net/trunk . ;# Accept the certificate. | ||
+ | sudo rm -f public | ||
+ | sudo ln -s roundcubemail public | ||
+ | sudo chmod ug+w roundcubemail/logs roundcubemail/temp | ||
+ | sudo chown -R $APACHE_USER:$APACHE_USER roundcubemail | ||
+ | </code> | ||
+ | |||
+ | Prepare the MySQL database. Be sure to save the username and password in the ''/root/.my.cnf'' file. (Use the real password and username below.) | ||
+ | |||
+ | <code bash> | ||
+ | PASSWORD=$PASSWORD | ||
+ | USER=$USER | ||
+ | sudo -H mysql <<EOF | ||
+ | CREATE DATABASE roundcube; | ||
+ | GRANT ALL PRIVILEGES ON roundcube.* TO $USER@localhost IDENTIFIED BY '$PASSWORD'; | ||
+ | FLUSH PRIVILEGES; | ||
+ | EOF | ||
+ | </code> | ||
+ | |||
+ | Make sure there's an Apache configuration for the site, and reload the Apache config if necessary. | ||
+ | |||
+ | ===== Configuration ===== | ||
+ | |||
+ | Browse to ''http://webmail.sluug.org/installer/''. | ||
+ | |||
+ | * Click ''START INSTALLATION'' button. | ||
+ | * Make sure all the requirements are met. Try to enable as many of the optional items as well. | ||
+ | * Click ''NEXT''. | ||
+ | * In ''General Configuration'': | ||
+ | * product_name = SLUUG Webmail | ||
+ | * CHECK ip_check | ||
+ | * CHECK Cache messages in local database | ||
+ | * In ''Database Setup'': | ||
+ | * Database name = roundcube | ||
+ | * Database user = $USER from above | ||
+ | * Database password = $PASSWORD from above | ||
+ | * In ''IMAP Settings'': | ||
+ | * default_host = ssl:/\/sluug.org | ||
+ | * port = 993 (for IMAPS) | ||
+ | * username_domain = sluug.org | ||
+ | * CHECK auto_create_user (allows automatic use for any IMAP user on our system) | ||
+ | * In ''SMTP Settings'': | ||
+ | * smtp_server = localhost | ||
+ | * smtp_port = 25 | ||
+ | * smtp_user/smtp_pass = (blank) | ||
+ | * In ''Display settings & user prefs'': | ||
+ | * pagesize = 12 | ||
+ | * UNCHECK prefer_html | ||
+ | * CHECK preview_pane | ||
+ | * draft_autosave = 3 min | ||
+ | * Click on ''CREATE CONFIG'' button. | ||
+ | * Save the 2 config files. | ||
+ | * Note that the ''download'' links don't work (they give a default config, not the one you just built); you'll have to cut and paste. | ||
+ | * Save the files in ''/srv/www/webmail.sluug.org/roundcubemail/config/'' with names of ''main.inc.php'' and ''db.inc.php'' | ||
+ | * Hit the ''CONTINUE'' button. | ||
+ | * The next page will test the config to see if everything is OK. | ||
+ | * The DB Schema will show as ''NOT OK (Database not initialized)'' | ||
+ | * Click on the ''Initialize database'' button. | ||
+ | * Now the DB Schema should show as ''OK'', along with DB Write and DB Time. | ||
+ | * Next, skip down to the ''Test SMTP config'' section. | ||
+ | * Enter a sender and recipient, then click the ''Send test email'' button. | ||
+ | * The page should come back with ''SMTP send: OK''. | ||
+ | * Next, skip down to the ''Test IMAP config'' section. | ||
+ | * Enter login info for an account on the IMAP server and click ''Check login''. | ||
+ | * The page should come back with ''IMAP connect: OK''. | ||
+ | |||
+ | Additional configuration can be done in the ''/srv/www/webmail.sluug.org/roundecubemail/config/main.inc.php'' file. | ||
+ | |||
+ | Remove the installation directory and some other files that are not needed: | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org/public | ||
+ | sudo rm -rf installer/ README INSTALL UPGRADING LICENSE CHANGELOG | ||
+ | </code> | ||
+ | |||
+ | |||
+ | ===== Upgrading ===== | ||
+ | **NOTE: It is highly recommended to ensure that nobody is logged into the webmail system when upgrading.** | ||
+ | |||
+ | First, make a backup of the current version, just in case. | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org | ||
+ | sudo cp -a roundcubemail roundcubemail.backup-`date +'%Y%m%d'` | ||
+ | </code> | ||
+ | |||
+ | Since we're using Subversion to download the code, we can simply pull the latest revision. First, check the current revision info: | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org | ||
+ | svn info | ||
+ | </code> | ||
+ | |||
+ | Then update to the latest revision: | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org | ||
+ | sudo svn up | ||
+ | svn info | ||
+ | </code> | ||
+ | |||
+ | Check the config files, to add any new parameters: | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org | ||
+ | diff -u roundcubemail/config/db.inc.php roundcubemail/config/db.inc.php.dist | ||
+ | diff -u roundcubemail/config/main.inc.php roundcubemail/config/main.inc.php.dist | ||
+ | </code> | ||
+ | |||
+ | Change anything necessary in the config files, then check the installation by browsing to ''/installer/''. | ||
+ | |||
+ | Once everything checks out, remove the unnecessary files again: | ||
+ | <code bash> | ||
+ | cd /srv/www/webmail.sluug.org/public | ||
+ | sudo rm -rf installer/ README INSTALL UPGRADING LICENSE CHANGELOG | ||
+ | </code> | ||
+ | ===== Usage ===== | ||
+ | |||
+ | Browse to ''http://webmail.sluug.org/''. | ||
+ | Log in with credentials against the IMAP(S) server. | ||
+ | ===== TODO ===== | ||
+ | |||
+ | Use PostgreSQL instead of MySQL. | ||
+ | |||
+ | Install PHP FileInfo package, which is optional, but recommended. | ||
+ | |||
+ | Consider configuring the logging differently. | ||
- | * Zimbra Collaboration Quite (5.0 appears to be installable without the email server) | ||
- | * RoundCube (a bit rough still, but good potential) | ||
- | * Horde (we tried, and it doesn't look like a good choice) | ||
- | * SquirrelMail (basic, but might be worth it if we can't get the others working) | ||