Bachelor Tech
  • Home
  • Tutorials
  • Portfolio
  • About Jan
  • Contact Jan

Services To Be Installed On Our Mail Server (OPTIONAL)

by Jan Bachelor October 31, 2024

Source: iRedmail documentation

Please note that there are usually more config and log files available for each service, I only highlight the ones you may need during our set up.

  • nginx → web server to display the admin interface (iRedAdmin) and webmail (RoundCube)
    • Config files:
      • /etc/nginx/nginx.conf → definition of the base user (e.g. www-data), max worker connections and additional resources to include.
      • /etc/nginx/sites-enabled/default.conf → default config for unencrypted communication, server and location directives
      • /etc/nginx/sites-enabled/default-ssl.conf → default config for encrypted comms, server and location directives
    • Log files:
      • /var/log/nginx/access.log → the default location for the access log.
      • /var/log/nginx/error.log → the default location for the error log.
  • dovecot → SMTP functionality
    • Config files:
      • /etc/dovecot/dovecot-mysql.conf → used to query mail users and passwords for MySQL / MariaDB engine.
      • /etc/dovecot/dovecot-pgsql.conf → used to query mail users and passwords on PostgreSQL engine.
      • /etc/dovecotr/dovecot-used-quota.conf → store and query per-user email quota.
    • Log files:
      • /var/log/dovecot/dovecot.log → log of changes to the dovecot service
      • /var/log/dovecot/imap.log → IMAP connection logs
  • postfix → for IMAP/LMTP/LDA
    • Config files:
      • /etc/postfix/main.cf → most config that we will be working with
      • /etc/postfix/master.cf → transport-related settings
      • /etc/postfix/mysql/*.cf → configs for MySQL / MariaDB
    • Log file: /var/log/mail.log
  • iRedAPD → a postfix policy server (default port 7777)
    • Config file: /opt/iredapd/settings.py
    • Log file: /var/log/iredapd/iredapd.log
  • iRedAdmin → web application (PHP-based, hence why we use nginx with the php-fpm package)
    • Config file: /opt/www/iredadmin/settings.py
    • Log file: /var/log/uwsgi/app/iredadmin.log
  • mariadb → database engine to store data in
    • Config files:
      • /etc/mysql/my.cnf → modify basic parameters like port number
      • /etc/mysql/mariadb.conf.d/50-server.cnf → server-related config (inc. SSL certificates)
      • /etc/mysql/mariadb.conf.d/50-client.cnf → client-related config
    • Log file: By default, it is integrated with syslog (run sudo cat /var/log/syslog | grep mysql)
  • mlmmj → a simple and slim mailing list manager (MLM) inspired by ezmlm. It works with many different Mail Transport Agents (MTAs).
    • Config file: /opt/mlmmjadmin/settings.py
    • Log file: /var/log/mlmmjadmin/mlmmjadmin.log
  • spamassassin → spam filtering service – called by amavis, not executed as a daemon
    • Config file: /etc/mail/spamassassin/local.cf
    • Log file: /var/log/mail.log
  • clamav → antivirus scan
    • Config files
      • /etc/clamav/clamd.conf → basic behavior of the AV
      • /etc/clamav/freshclam.conf → AV database configuration
    • Log files:
      • /var/log/clamav/clamav.log → records of findings (must be activated via clamd.conf – remove the ‘#’ to uncomment a line starting with ‘#LogFile’.
      • /var/log/clamav/freshclam.log → AV database update log
  • RoundCube – webmail (optional but recommended to install)
    • Config file: /opt/www/roundcubemail/config/config.inc.php → here we can disable the requirement to run on HTTPS internally
    • Log file: Postfix log is used by default
  • php-8.2 inc. the fpm package that is used for compatibility with nginx
  • fail2ban (optional) – auto-ban repeated failed login attempts
    • Config file: /etc/fail2ban/jail.local
    • Log file: /var/log/fail2ban.log
  • nftables (optional) → a new generation iptables firewall (can be replaced by ufw)
  • netdata → system application monitor
  • amavis (amavisd-new) → analysis and filtering capabilities, works with postfix and spamassasin, uses external content filters and changes ratings of senders. Helps with the generation of the DKIM record
    • Config file: /etc/amavis/conf.d/50-user
    • Log file: stored in postfix logs by default
  • rsyslog → the ‘rocket-fast’ system for log processing

This is why our VM needs at least 3 GB of RAM!

HAProxy Set Up - SSL termination (OPNSense)
iRedMail installation (Debian)
Go back to course overview: Install iRedMail Mail Server As Proxmox VM With OPNSense As Firewall

Leave a Comment Cancel Reply

Save my name, email, and website in this browser for the next time I comment.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 FacebookWhatsappEmail

Course Steps

  1. Starting Point and Considerations
  2. Pointing Your MX Records (DNS)
  3. Generic VM Installation (Proxmox)
  4. Firewall - static DHCP assignment (OPNsense)
  5. Firewall - Ports to open on your firewall (OPNSense)
  6. Fiirewall- Set Up NAT Rules (OPNSense)
  7. Dynamic DNS for our ‘mail’ DNS record (CloudFlare with OPNSense)
  8. Get SSL Certificate on OPNSense for Web Services (CloudFlare)
  9. HAProxy Set Up - SSL termination (OPNSense)
  10. Services To Be Installed On Our Mail Server (OPTIONAL)
  11. iRedMail installation (Debian)
  12. Nginx Configuration (Debian)
  13. Access iRedAdmin
  14. Configure Roundcube
  15. CertBot Certificate Creation
  16. Apply Certificates - Nginx
  17. A Theory Crash Course On Postfix (OPTIONAL)
  18. Securing Your Mail Server (Postfix)
  19. SMTP Relay With Brevo
  20. Testing your outgoing email ranking
  21. Connect Your Device To The Mail Server Via Email Client
Previous Next

Recent Comments

  • Jan Bachelor on Dynamic DNS Set Up with DuckDNS on OPNSenseHi Jake, that's awesome, congratulations on getting…
  • Jake on Dynamic DNS Set Up with DuckDNS on OPNSensefollowed guide above to the T and all is working. i…
  • Fastbrain on Dynamic DNS Set Up with DuckDNS on OPNSenseThanks for the guide. For some reason, after follow…

Other courses

Install iRedMail Mail Server As Proxmox VM With...

October 31, 2024

Remote Bucket Storage for Proxmox VM Backups

August 16, 2024

Concur Alternative: Import Employees’ Credit Card Expenses to...

January 19, 2024

Create an automated Gravity workflow that will allow...

January 19, 2024

Dynamically Populate Gravity Forms from Google Sheets (GSheets...

March 16, 2021
Bachelor Tech
  • Home
  • Tutorials
  • Portfolio
  • About Jan
  • Contact Jan

Recent Posts

  • How to join two Proxmox nodes into a cluster (PVE 8.x)

  • How to Rename a Proxmox Node

  • How to mount an NFS share on an Android box

Facebook Twitter Instagram Pinterest Linkedin Youtube

All Rights Reserved. The theme was customized from Soledad, see PenciDesign