No description
Find a file
Heiko Schlittermann (HS12-RIPE) b18e40809c
Squashed commit of the following:
commit 511d4e85c8e2e8a3521ae428e08bb02274242364
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Sun Jan 4 10:41:04 2026 +0100

    new: strip down to the bare minimum OCI image

    No magic install routines and such. See the compagnion repo
    https://git.schlittermann.de/heiko/exim-container-shell

commit 76d7442d214a2b8c6cf8e57471c9d8ef7b82f08c
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Sat Jan 3 16:42:34 2026 +0100

    registry: oci.schlittermann.de

commit 6b28712572d140ab816be8a9e9051f00aceb428c
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Fri Jan 2 23:55:42 2026 +0100

    debian: build package

commit d45f0e3f34
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Thu Jan 1 18:25:08 2026 +0100

    new: service and wrapper

commit b8e7c90102
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Thu Jan 1 18:04:31 2026 +0100

    fix: compose ports

commit 0bb1019b20
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Dec 30 18:33:42 2025 +0100

    sm: rename exim->exim-src

commit 596d91c764
Merge: 4fd4fcd cb0f86d
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Dec 30 16:53:19 2025 +0100

    Merge branch 'master' into dev/wip

    * master:
      new: create exim and exim-admin images

commit 4fd4fcde85
Merge: e4f07fd 837c064
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Dec 29 23:53:20 2025 +0100

    Merge branch 'master' into dev/wip

    * master:
      Squashed commit of the following:

commit e4f07fd08a
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Dec 29 23:51:43 2025 +0100

    new: target exim-base, exim-daemon, exim-admin

commit 32216394b3
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Dec 29 23:24:01 2025 +0100

    exim: adjust buildconfig to match 4.99.1

commit 3bc2274ce0
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Dec 29 22:50:56 2025 +0100

    chg: better target names in Dockerfile

commit cf74ac24c7
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Dec 29 22:16:49 2025 +0100

    sm: update to exim-4.99+fixes (currently 4.99.1)

commit 593eef5b54
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Nov 17 23:52:06 2025 +0100

    doc: link docs from doc/ dir

commit fff01c7da0
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Sun Nov 16 21:16:09 2025 +0100

    new: eximsh

commit b3bb5d3831
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Sun Nov 16 21:16:00 2025 +0100

    git: clean

commit c224e1cf1d
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Sun Nov 16 18:43:29 2025 +0100

    doc: fix picture layout

commit 4566395cf1
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Wed Nov 12 18:16:57 2025 +0100

    proxy: no bashism

commit f292a7983a
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Wed Nov 12 18:06:53 2025 +0100

    fix: systemd service files

commit 74e92a7bfa
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Wed Nov 12 18:00:07 2025 +0100

    fix: proxy name

commit 23dcacd0b5
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 23:11:57 2025 +0100

    new: install "entrypoint"

commit 6aae044a86
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 23:11:34 2025 +0100

    chg: rename exim.tool to exim-container-proxy

commit 2413bf5e6f
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 23:10:45 2025 +0100

    doc: how to startup (volumes, ports)

commit c2fbfe545c
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 22:44:59 2025 +0100

    fix: entrypoint file permissions adjustment

commit 0a1c0a5075
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 17:46:30 2025 +0100

    git: move the playground compose file to a separate directory

    Maybe we can do the system integration using a compose file.

commit c82f567c0f
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 17:45:22 2025 +0100

    doc: adjust general README

commit 1c55540fd0
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Tue Nov 11 16:37:58 2025 +0100

    update to Debian 13 / trixie

commit 5f59c51c44
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Sep 8 18:23:39 2025 +0200

    doc: update to trixie

commit d792ece170
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Sep 8 18:23:22 2025 +0200

    new: guard for env CONTAINER

commit 11a5f795b4
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Sep 8 15:24:07 2025 +0200

    doc: provide more outline

commit 989726a996
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Sep 8 14:40:39 2025 +0200

    doc: split README and doc/

commit 29e2992816
Author: Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de>
Date:   Mon Sep 8 14:09:29 2025 +0200

    wip
2026-01-04 10:42:11 +01:00
assets Squashed commit of the following: 2026-01-04 10:42:11 +01:00
doc Squashed commit of the following: 2026-01-04 10:42:11 +01:00
ex declare minimal config as such 2024-11-10 00:15:35 +01:00
exim-src@d46a672779 Squashed commit of the following: 2026-01-04 10:42:11 +01:00
system-integration Squashed commit of the following: 2026-01-04 10:42:11 +01:00
.dockerignore rework for bullseye and 4.95 2022-10-15 11:22:59 +02:00
.editorconfig Add .editorconfig 2017-12-07 22:34:31 +01:00
.gitignore Squashed commit of the following: 2026-01-04 10:42:11 +01:00
.gitmodules Squashed commit of the following: 2026-01-04 10:42:11 +01:00
Dockerfile Squashed commit of the following: 2026-01-04 10:42:11 +01:00
Makefile Squashed commit of the following: 2026-01-04 10:42:11 +01:00
README.md Squashed commit of the following: 2026-01-04 10:42:11 +01:00

Run Exim via Docker / Podman

Using a container environment like Docker or Podman for running Exim does not imply anything like Swarm, Compose, Kubernetes or similar. Though it can be understood as a first step towards such scalable environment. But definitively there is nothing forcing you do go this step.

Rationale

Exim has a versatile built time config. Depending on your target's operating system variant (distribution, version, …) dependency issues might arise for custom builds.

Containerization provides a high isolation level between the target host OS and the application. Libraries inside the containerized application do not conflict with libraries of the host operating system.

This isolation provides pros and cons.

Outline

Using container technology does not imply using Kubernetes or any other scaling technologies. By its very heart, we're still using a single Exim instance on a single host.

The Exim binary runs under control of the container runtime. A limited subset of files and directories of the host system will be mounted into the running container, and the running container will listen on a limited set of host ports:

 -----------[host os]---------------------------------
         ,--[container runtime]------.
         |                           |
         |   ,-[Exim container]-.    |
         |   |                  |    |
    25/tcp --+   application    +-- /var/spool/exim (rw)
   465/tcp --+   • tools        +-- /var/log/exim   (rw)
   587/tcp --+   • libraries    +-- /etc/exim       (ro)
         |   `------------------'   |
         `--------------------------'

The container gets started and shut down by a Systemd service.

Tools like exigrep are installed inside the container and run inside the container (no interaction with the host OS, except for the mounted directories).

Wrapper scripts are installed on the host, which allow transparent execution of these tools. Basically these wrapper scripts run podman exec exim exigrep …

Pros

The container image build process is independent on the target operation system. The build can be done on any host with a container build toolchain installed and can use any (Linux) environment which fits the application's build requirements. (We use Debian, though Fedora would be an other good starting point. The development of Exim is done using Fedora and Debian.)

The container image can be updated independent on updates of the host OS, as long as the container's runtime environment is supported (We're focusing on Podman, as this is a native RedHat component.)

Tools for running the containerized application can be installed inside, or can even be provided already pre-bundled with the container image.

Cons

There a no dependencies between the host's environment (library versions) and the the containerized application. Updates of the containerized application are not covered by normal OS updates.

Responsibility for application (and supporting libraries) updates now shifts to the provider of the container image. (This itself can be seen as a con, as the "os team" can do OS updates w/o aligment with the "application team".)

Admin access to the containerized application and its helper scripts requires an additional layer of execution. Though this can be scripted and is as transparent as possible.

Requirements

The only hard requirement is a container runtime, preferably Podman. It is provided by all major distributions, including RedHat.

For an easy installation and update process, a container image registry is highly recommended.

Execution

Just run ${container} run --rm exim to get the Exim instance running (and stopping). It behaves like any nativ Exim on the host would behave.

For normal operation you need to mount volumes from the host to the container:

  • config:
    • either a single config file: /etc/exim/exim.conf
    • or a complete directory: /etc/exim
  • log dir: /var/log/exim (ownership will adjusted to the exim runtime user and group)
  • spool dir: /var/spool/exim (ownership will adjusted to the exim runtime user and group)
  • lib dir: /var/lib/exim (ownership won't be touched, should probably be read only)

More: details on running the image standalone.

Build

In case you need to re-build the image(s): details.

Install

Please see the install guide

Rootless

wip

  • required packages:
    • uidmap

Compose

For Podman: enable a compose provider: example.