feat: ajout Postfix, Rspamd et ClamAV dans docker-compose-dev

Services internes (aucun port exposé sur l'hôte) :
- Postfix (boky/postfix) : SMTP interne, hostname mail.siteconseil.local,
  domaines autorisés siteconseil.fr/siteconseil.local, milter vers Rspamd
  sur port 11332, healthcheck via postfix status
- Rspamd (rspamd/rspamd) : filtrage spam/phishing, connecté à ClamAV,
  milter protocol 6 pour Postfix
- ClamAV (clamav/clamav:stable) : antivirus, healthcheck clamdcheck,
  start_period 120s pour le téléchargement initial des signatures

Chaîne : PHP → Postfix:25 → Rspamd:11332 → ClamAV:3310
Volumes persistants : postfix-data, rspamd-data, clamav-data

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Serreau Jovann
2026-04-03 14:24:52 +02:00
parent ef9b6a418d
commit caf7869e8c

View File

@@ -184,6 +184,57 @@ services:
redis:
condition: service_healthy
postfix:
image: boky/postfix:latest
container_name: crm_siteconseil_postfix
restart: unless-stopped
hostname: mail.siteconseil.local
environment:
ALLOWED_SENDER_DOMAINS: siteconseil.fr siteconseil.local
RELAYHOST: ""
POSTFIX_myhostname: mail.siteconseil.local
POSTFIX_mydestination: siteconseil.local, localhost
POSTFIX_mynetworks: "10.0.0.0/8 172.16.0.0/12 192.168.0.0/16"
POSTFIX_smtpd_milters: "inet:rspamd:11332"
POSTFIX_non_smtpd_milters: "inet:rspamd:11332"
POSTFIX_milter_protocol: "6"
POSTFIX_milter_default_action: "accept"
volumes:
- postfix-data:/var/spool/postfix
depends_on:
rspamd:
condition: service_started
healthcheck:
test: ["CMD-SHELL", "postfix status || exit 1"]
interval: 10s
timeout: 5s
retries: 5
rspamd:
image: rspamd/rspamd:latest
container_name: crm_siteconseil_rspamd
restart: unless-stopped
volumes:
- rspamd-data:/var/lib/rspamd
depends_on:
clamav:
condition: service_healthy
environment:
- CLAMAV_HOST=clamav
clamav:
image: clamav/clamav:stable
container_name: crm_siteconseil_clamav
restart: unless-stopped
volumes:
- clamav-data:/var/lib/clamav
healthcheck:
test: ["CMD-SHELL", "clamdcheck || echo 0"]
interval: 30s
timeout: 10s
retries: 5
start_period: 120s
volumes:
db-data:
redis-data:
@@ -191,3 +242,6 @@ volumes:
vault-data:
meilisearch-data:
libretranslate-data:
postfix-data:
rspamd-data:
clamav-data: