This is instruction from me, if you want to setup mail server and use IMAP Server on Ubuntu or Debian and access the e-mail from SquirrelMail web-base. It’s work for me.
My system
- Ubuntu Server 9.04
- Install Postfix mail transfer agent
- Install Courier imap
- Install Apache and PHP5 for website
- Install SquirrelMail for webmail access
- Configuration of SquirrelMail
- Configuration your server and software for IMAP
- Attach SquirrelMail to Apache2
- Enable Squirrelmail
- Restart Apache2
- Connect to SquirrelMail
- Create directory for stored certificate file
- Create certificate file name apache2.pem
- Enable mod SSL
- Create file for virtualsite in apache2
- Enable site SquirrelMail with SSL
- Restart Apache2
aptitude install postfix
aptitude install courier-imap courier-imap-ssl
aptitude install apache2 libapache2-mod-php5
aptitude install squirrelmail
squirrelmail-config
1 (config your Organization name)
2->A->8 ->courier (config your server setting)
cp /etc/squirrelmail/apache.conf /etc/apache2/sites-available/squirrelmail
a2ensite squirrelmail
invoke-rc.d apache2 restart
If you want to access the SquirrelMail via SSL (https://yourserver) the instruction below explain how to make it.
mkdir /etc/apache2/ssl
make-ssl-cert /usr/share/ssl-cert/ssleay.cnf /etc/apache2/ssl/apache2.pem
a2enmod ssl
nano /etc/apache2/site-available/squirrelmail-ssl
[html]
<IfModule mod_ssl.c>
<VirtualHost *:443>
DocumentRoot /usr/share/squirrelmail
SSLEngine on
SSLCertificateFile /etc/apache2/ssl/apache2.pem
<Directory /usr/share/squirrelmail>
Options Indexes FollowSymLinks
<IfModule mod_php4.c>
php_flag register_globals off
</IfModule>
<IfModule mod_php5.c>
php_flag register_globals off
</IfModule>
<IfModule mod_dir.c>
DirectoryIndex index.php
</IfModule>
<Files configtest.php>
order deny,allow
deny from all
allow from 127.0.0.1
</Files>
</Directory>
</VirtualHost>
</Ifmodule>
[/html]
a2ensite squirrelmail-ssl
invoke-rc.d apache2 restart