Installing Horde on Debian Jessie

Below is a guide to installing Horde mail & groupware server on Debian Jessie.  Starting with base system already installed:

Install the Email server (MTA):
We need a working mail system, here we use sendmail with dovecot providing IMAP:
 apt-get install sendmail

Configure domain & SMTP settings:
 nano /etc/mail/local-host-names
 nano /etc/
 make -C /etc/mail
 /etc/init.d/sendmail reload

Install an IMAP provider:
 apt-get install dovecot-imapd
Allow plaintext authentication temporarily (or configure TLS certificate?):
 nano /etc/mail/…
Test a local user authentication:
 telnet 143
 a login
 b select inbox

Install the web server:
 apt-get install apache2

Install the database server:
There are no instructions or guides explaining how to use sqlite, so we will use postgresql since it has fewer dependencies than mysql. We need to create a user and a blank database that will be used by Horde.
 apt-get install postgresql
  su – postgres
  ALTER USER horde PASSWORD ‘new-password’;
  CREATE horde
Test the new postgresql user:

 psql -U horde -W

Install Horde:
 apt-get install php-horde-webmail
 apt-get install php5-postgres
 cd /etc/horde/imp
 cp backends.php backends.local.php
 nano backends.local.php
  (remove unnecessary lines)
  (change the imap ‘secure’ setting from ‘tls’ to ‘no security’)
 /etc/init.d/apache2 restart

Try to log in via web interface, using a local user account:

To create an Administrator log into mysql as horde user, select horde database and execute this.

 INSERT INTO horde_users (user_uid, user_pass) VALUES (‘admin’, ‘wDa72Pg6riJ6vAYz25KbYhQ8rGqmEqEA’);
(this sets new user admin with password “admin”)

*Debian php-horde includes a script at /usr/share/php/data/horde/scripts/sql
that sets an Administrator user, but it’s use is not documented.

Try to access the admin site:

Enable SMTP:
Set up the receive domain:
 nano /etc/mail/local-host-names

Set up the email address aliases:
 nano /etc/mail/aliases
  aliasname: username

Enable SMTP daemon to listen on all IP addresses:
 nano /etc/mail/
   DAEMON_OPTIONS(`Family=inet,  Name=MTA-v4, Port=smtp, Addr=′)dnl
 /etc/init.d/sendmail restart