update
This commit is contained in:
7
mail/README.md
Normal file
7
mail/README.md
Normal file
@@ -0,0 +1,7 @@
|
||||
To reset counters/stats:
|
||||
$ docker exec -it mail bash
|
||||
# curl -X POST http://localhost:11334/statreset
|
||||
|
||||
To learn spam
|
||||
# cd /var/mail/saltaire.com.au/greg.johnson/.Junk/cur
|
||||
# rspamc learn_spam .
|
||||
79
mail/compose.yml
Normal file
79
mail/compose.yml
Normal file
@@ -0,0 +1,79 @@
|
||||
|
||||
name: mail
|
||||
|
||||
services:
|
||||
mail:
|
||||
container_name: mail
|
||||
image: mailserver/docker-mailserver:15.1.0
|
||||
restart: unless-stopped
|
||||
stop_grace_period: 1m
|
||||
hostname: mail.saltaire.com.au
|
||||
ports:
|
||||
- "25:25" # SMTP (explicit TLS => STARTTLS)
|
||||
- "143:143" # IMAP4 (explicit TLS => STARTTLS)
|
||||
- "465:465" # ESMTP (implicit TLS)
|
||||
- "587:587" # ESMTP (explicit TLS => STARTTLS)
|
||||
- "993:993" # IMAP4 (implicit TLS)
|
||||
environment:
|
||||
ENABLE_FAIL2BAN: 1
|
||||
ENABLE_QUOTAS: 0
|
||||
|
||||
# Rspamd
|
||||
ENABLE_RSPAMD: 1
|
||||
# ClamAV is compatible with Rspamd
|
||||
ENABLE_CLAMAV: 0
|
||||
# Rspamd replaces the functionality of these anti-spam services, disable them:
|
||||
ENABLE_AMAVIS: 0
|
||||
ENABLE_OPENDKIM: 0
|
||||
ENABLE_OPENDMARC: 0
|
||||
ENABLE_POLICYD_SPF: 0
|
||||
ENABLE_POSTGREY: 0
|
||||
ENABLE_SPAMASSASSIN: 0
|
||||
|
||||
# empty => 10240000 (~10 MB)
|
||||
POSTFIX_MESSAGE_SIZE_LIMIT: 81920000
|
||||
|
||||
# Rspamd options
|
||||
RSPAMD_GREYLISTING: 1
|
||||
RSPAMD_LEARN: 1
|
||||
|
||||
SPOOF_PROTECTION: 1
|
||||
SSL_TYPE: letsencrypt
|
||||
|
||||
LOG_LEVEL: info
|
||||
networks:
|
||||
- proxy
|
||||
volumes:
|
||||
- type: volume
|
||||
source: proxy_data
|
||||
target: /etc/letsencrypt/live/mail.saltaire.com.au/fullchain.pem
|
||||
volume:
|
||||
nocopy: true
|
||||
subpath: caddy/certificates/acme-v02.api.letsencrypt.org-directory/mail.saltaire.com.au/mail.saltaire.com.au.crt
|
||||
- type: volume
|
||||
source: proxy_data
|
||||
target: /etc/letsencrypt/live/mail.saltaire.com.au/privkey.pem
|
||||
volume:
|
||||
nocopy: true
|
||||
subpath: caddy/certificates/acme-v02.api.letsencrypt.org-directory/mail.saltaire.com.au/mail.saltaire.com.au.key
|
||||
- data:/var/mail/
|
||||
- logs:/var/log/mail/
|
||||
- state:/var/mail-state/
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
- ./config/:/tmp/docker-mailserver/
|
||||
- ./config/cron/sa-learn:/etc/cron.d/sa-learn
|
||||
cap_add:
|
||||
- NET_ADMIN
|
||||
healthcheck:
|
||||
test: "ss --listening --tcp | grep -P 'LISTEN.+:smtp' || exit 1"
|
||||
timeout: 3s
|
||||
retries: 0
|
||||
networks:
|
||||
proxy:
|
||||
external: true
|
||||
volumes:
|
||||
data:
|
||||
logs:
|
||||
state:
|
||||
proxy_data:
|
||||
external: true
|
||||
Reference in New Issue
Block a user