A simple docker-compose and Dockerfile to davmail.
Contents of the davmail directory was downloaded from Sourceforge.
Using the davmail.mode=O365Modern is a little bit tricky, because a session token always needs to be refreshed. Luckily, davmail does this, but first we need to give it permission. So for the first run:
- Change the log levels in the
davmail.propertiestoDEBUG - When the authentication fails, click the link in the logs and give it permission in the O365.
- You can set back the log levels. From this point, it will be handled.
-
davmailconfiguration can be found indavmail.properties.
It is the same as recommended in the Server Setup, except:davmail.mode=O365Modern(see above)
-
IMAPport is mapped to7007(indocker-compose.yml) -
SMTPport is mapped to7008(indocker-compose.yml) -
All other
davmailsupported ports are not exposed.