Getting started

This document will show you how to get up and running with mailserver. You will get your email server running, delivering and receiving emails in 5 minutes.


For fully functional internet available email server you need couple things:

  • any 64bit linux distribution running in virtual machine or dedicated server
  • CPU and free RAM to run Spamassassin and Clamav. Other components are not so CPU and memory hungry
  • Docker engine running - see how to install docker engine
  • public IP address
  • ability to change IP address's reverse DNS entry - contact your service provider if you are not able to do it by yourself
  • full access to domain DNS administration

Downloading and running

There are two versions of product, PRO and FREE image.

PRO version # (from docker server)
Free version
analogic/ # (from

Both versions share same data directory structure - the only one difference when running PRO version is that you will login to our private docker repository.

PRO version
$ docker login -u "username" -p "password"
$ docker run \
    --net=host \
    -e TZ=Europe/Prague \
    -v /your-data-dir/data:/data \
    --name "mailserver" \
    -h "" \
Free version

You will be using image from public Docker hub.

$ docker run \
    --net=host \
    -e TZ=Europe/Prague \
    -v /your-data-dir/data:/data \
    --name "mailserver" \
    -h "" \
    -t analogic/

Docker arguments explained

Ports which are opened by

Port numberPurpose
25SMTP - mostly processing incoming mails
80HTTP - redirect to https (see options) and authentication for Let's encrypt service
110POP3 - standard protocol for accessing mailbox, STARTTLS is required before client auth
143IMAP - standard protocol for accessing mailbox, STARTTLS is required before client auth
443HTTPS - access to administration or webmail client
465SMTPS - Legacy SMTPs port
587MSA - SMTP port used primarily for email clients after STARTTLS and auth
993IMAPS - alternative port for IMAP encrypted since connection
995POP3S - encrypted POP3 since connections
4190Sieve - remote sieve settings
  • -e TZ=Europe/Prague Set timezone for correct datetime

  • -v /your-data-dir/data:/data Mounts data directory from host system. User database, emails, logs, all will end up in this directory for easy backup.

  • --name "mailserver" Run as container with defined name

  • -h "" Hostname for your mailserver

  • -t analogic/ Image name, differs for PRO and FREE version

Optional arguments

  • -e "HTTPS=OFF" To disable all redirects to encrypted HTTP, its useful when you are using some kind of reverse proxy (place this argument before image name!)

  • -e "HTTP_PORT=8080" Custom HTTP port. Please note that you must handle Let's encrypt requests at port 80, so if you are using reverse proxy setup you need to forward /.well-known/ folder to this port

  • -e "HTTPS_PORT=4433" Custom HTTPS port.

  • -e "DISABLE_CLAMAV=TRUE" To disable all ClamAV, it is useful for low mem usage.

  • -e "DISABLE_RSPAMD=TRUE" To disable all Rspamd, it is useful for low mem usage.

  • -e "DISABLE_ROUNDCUBE=TRUE" To disable Roundcube webmail.

  • -p 4190:4190 When you are going to use clients with ability to manage Sieve filters externally, you need also publish port 4190