The simple and secure account managing application for your mailserver.
This web application can be used for mailservers running Postfix and Dovecot and a database with virtual mail users.
You can run MailMan in two different modes:
- Everyone can sign up and create a new mail account - Admins can create blacklists for usernames
- Only people with an invite token/link can create an account - Admins can choose how long the invitation is valid - Admins can preset a username if wanted, otherwise the invitee can feel free to choose one themself
There are two types of users: the admin users and the mail users.
- Create, edit and delete users (both admins and mail users)
- Create invite tokens/links
- Create mail aliases
- Create blacklists for usernames
- Create muptiple mail domains
- Change own password
- TODO See account details
- TODO Configure aliases
- Webserver (e.g. NGINX or Apache)
- PHP (version 7.2 or above)
- Database (e.g. MariaDB, MySQL or PostgreSQL)
- Postfix
- Dovecot
- Clone this repository.
- Set up a webserver with PHP7.2 or above and all the Laravel dependancies.
- Configure the document root of the webserver to point to the
public
directory of this repository. - Install the Composer software and run
composer update
while being in the root directory of this repository. - Copy or rename the
.env.example
file to.env
and edit the file to contain your correct database credentials, timezone and so on. - Run
php artisan migrate:fresh
to create the database structure. - Run
php artisan db:seed
to create a default admin user.
- Copy the .cf files from the
postfix
directory from this repository into your local postfix configuration directory (e.g./etc/postfix/
) - Add the following lines to the
main.cf
file of your local Postfix config directory (assuming you are using MySQL or MariaDB):
virtual_mailbox_domains = mysql:/etc/postfix/mailman-domains.cf
virtual_mailbox_maps = mysql:/etc/postfix/mailman-users.cf
virtual_alias_maps = mysql:/etc/postfix/mailman-aliases.cf
- Edit each of those three files so that they conatin the correct database credentials.
- Restart or reload the Postfix service: e.g.
postfix reload
Go to your Dovecot config directory on your system (e.g. /etc/dovecot/
) and add the following lines to the dovecot-sql.conf.ext
file:
driver = mysql
connect = host=127.0.0.1 dbname=dbname user=dbusername password=dbpassword
default_pass_scheme = SHA512-CRYPT
password_query = SELECT * FROM (SELECT CONCAT(u.username, '@', d.name) as user, password FROM users u JOIN domains d ON (u.domain_id=d.id)) x WHERE user='%u';
Don't forget to replace the placeholders in the line starting with connect
with your correct database credentials.
Admin-login page: /admin
Username: admin
Password: admin
Make sure to change the administrator password IMMEDEATELY after installation!
This project is licensed under the GNU General Public License Version 3 - see the LICENSE file for details.