Installation Documentation

Contents

0. Notes
1. Before installation
2. Download dracMail
3. Extract
4. Configure

0. Notes

This installation guide applies for release version 0.1.
For the current beta version read the INSTALL file found in the archive.


1. Before installation

Before installing dracMail your server must have these packages installed:
NOTES: You should have an IMAP server up and running. If you decide installing your own, you could try qmail.
  dracMail has been developed and tested on FreeBSD, however it is compatible with any Linux distribution that supports the above packages.
  PHP should be enabled as an Apache module.


2. Download dracMail

You can manually download dracMail from sourceforce.net: http://sourceforge.net/projects/dracmail/files/beta/dracMail-0.1.2_release.tar.gz/download, or using ftp:

ftp http://sourceforge.net/projects/dracmail/files/beta/dracMail-0.1.2_release.tar.gz/download

Once downloaded, you should verify the md5 sum: MD5 (dracMail-0.1.2_release.tar.gz) = 7bfc625c1fe7a4d81412593f02977ab3


3. Extract

Move or upload the file to your public_html folder, and extract:

tar -zxvf dracMail-0.1_beta.tar.gz


4. Configure

After PHP, Apache and MySQL have been properly installed and configured, the last step is configuring dracMail itself.

Prepare the MySQL Server:

Login with the root user (or a user with CREATE permissions):

mysql -u root -p

Add a new user: CREATE USER 'WEBMAIL_USERNAME'@'localhost' IDENTIFIED BY 'PASSWORD';

Create a new database: CREATE DATABASE WEBMAIL_DATABASE_NAME;

Select the new database: USE 'WEBMAIL_DATABASE_NAME';

Load the database tables from 'dracmail.sql', found in './api/SQL/': SOURCE ./api/SQL/dracmail.sql;

Add SELECT, INSERT, DELETE and UPDATE permissions for the new user: GRANT SELECT, INSERT, UPDATE, DELETE ON
WEBMAIL_DATABASE_NAME.* TO WEBMAIL_USERNAME@localhost;

Flush privileges: FLUSH PRIVILEGES;

Quit mysql: QUIT;


NOTES: WEBMAIL_USERNAME, WEBMAIL_DATABASE_NAME and PASSWORD should be changed to your own.

Change the current directory to the API directory:

cd ./api/

Prepare the configuration file:

cp configuration.php.sample configuration.php

Edit using your favourite editor, and change the following settings:

IMAP Server configuration:

define('IMAP_SERVER_HOST', "localhost"); // Your server hostname, default to 'localhost'
define('IMAP_SERVER_PORT', "143"); // Your server port, default to 143

MySQL Server configuration:

define('MYSQL_HOST', 'localhost'); // Your MySQL server hostname, default to 'localhost'
define('MYSQL_USER', 'WEBMAIL_USERNAME'); // Your webmail username
define('MYSQL_PASS', 'PASSWORD'); // Your webmail user password
define('MYSQL_DB', 'WEBMAIL_DATABASE_NAME'); // Database name, default to 'dracmail'


NOTES: First time login will create default user folders if they do not exist. To configure the process you can have a look at the $folderMapping variable in the configuration file.
  Once the installation is done, be sure to remove the sample configuration file (api/configuration.php.sample).

That's it. The installation is done.