OK, https://github.com/loomio/mailin-docker/blob/master/Dockerfile is the Dockerfile. mailin listens on port 25 and calls a webhook. Listening on port 25 won't work on Cloudron, so that solution is unviable. We have to write a standalone script that scans IMAP mailbox and calls the wekhook. mailin code that calls the webhook is at https://github.com/loomio/mailin/blob/master/lib/mailin.js .