2020-12-27 19:41:35 +01:00
|
|
|
version: '2.2'
|
|
|
|
|
|
|
|
services:
|
|
|
|
|
|
|
|
# External dependencies
|
|
|
|
redis:
|
|
|
|
image: redis:alpine
|
|
|
|
restart: always
|
2021-10-11 22:40:26 +02:00
|
|
|
env_file: mailu.env
|
2020-12-27 19:41:35 +01:00
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "redis_data:/data"
|
2022-01-21 18:09:56 +01:00
|
|
|
healthcheck:
|
|
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
|
|
interval: 1s
|
|
|
|
timeout: 3s
|
|
|
|
retries: 30
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-05-23 00:01:22 +02:00
|
|
|
depends_on:
|
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
|
|
|
|
2020-12-28 17:24:45 +01:00
|
|
|
database:
|
|
|
|
image: mariadb
|
|
|
|
restart: always
|
|
|
|
environment:
|
|
|
|
MYSQL_DATABASE: "mailu"
|
|
|
|
MYSQL_USER: "mailu"
|
|
|
|
MYSQL_PASSWORD: "{{mailu_database_password}}"
|
2022-11-16 12:28:16 +01:00
|
|
|
MYSQL_ROOT_PASSWORD: "{{mailu_database_password}}"
|
2023-04-15 18:11:25 +02:00
|
|
|
MARIADB_AUTO_UPGRADE: "1"
|
2020-12-28 17:24:45 +01:00
|
|
|
volumes:
|
|
|
|
- database:/var/lib/mysql
|
2022-01-21 00:11:06 +01:00
|
|
|
healthcheck:
|
2023-06-21 12:56:28 +02:00
|
|
|
test: "/usr/bin/mariadb --user=mailu --password={{mailu_database_password}} --execute \"SHOW DATABASES;\""
|
2022-01-21 00:11:06 +01:00
|
|
|
interval: 3s
|
|
|
|
timeout: 1s
|
|
|
|
retries: 5
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-05-23 00:01:22 +02:00
|
|
|
depends_on:
|
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2023-05-23 00:23:41 +02:00
|
|
|
networks:
|
|
|
|
- default
|
|
|
|
- webmail
|
|
|
|
- radicale
|
2022-01-29 19:21:46 +01:00
|
|
|
|
2020-12-27 19:41:35 +01:00
|
|
|
# Core services
|
2023-05-23 00:01:22 +02:00
|
|
|
resolver:
|
|
|
|
image: ghcr.io/mailu/unbound:{{mailu_version}}
|
|
|
|
env_file: mailu.env
|
|
|
|
restart: always
|
|
|
|
networks:
|
|
|
|
default:
|
|
|
|
ipv4_address: 192.168.203.254
|
|
|
|
logging:
|
|
|
|
driver: journald
|
|
|
|
|
2020-12-27 19:41:35 +01:00
|
|
|
front:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/nginx:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
logging:
|
2022-01-29 19:21:46 +01:00
|
|
|
driver: journald
|
2020-12-27 19:41:35 +01:00
|
|
|
ports:
|
2020-12-27 23:14:11 +01:00
|
|
|
- "127.0.0.1:{{ http_port }}:80"
|
2020-12-27 19:41:35 +01:00
|
|
|
- "{{ ip4_address }}:25:25"
|
|
|
|
- "{{ ip4_address }}:465:465"
|
2022-11-17 14:47:25 +01:00
|
|
|
- "{{ ip4_address }}:{{system_email_port}}:{{system_email_port}}"
|
2020-12-27 19:41:35 +01:00
|
|
|
- "{{ ip4_address }}:110:110"
|
|
|
|
- "{{ ip4_address }}:995:995"
|
|
|
|
- "{{ ip4_address }}:143:143"
|
|
|
|
- "{{ ip4_address }}:993:993"
|
|
|
|
volumes:
|
2023-04-15 19:48:46 +02:00
|
|
|
- "/etc/mailu/overrides/nginx:/overrides:ro"
|
2021-04-05 12:32:55 +02:00
|
|
|
- "/etc/mailu/certs:/certs"
|
2022-01-21 00:11:06 +01:00
|
|
|
depends_on:
|
2023-05-23 00:01:22 +02:00
|
|
|
resolver:
|
|
|
|
condition: service_started
|
2022-01-21 00:11:06 +01:00
|
|
|
database:
|
|
|
|
condition: service_healthy
|
2023-05-23 00:01:22 +02:00
|
|
|
networks:
|
|
|
|
- default
|
|
|
|
- webmail
|
|
|
|
- radicale
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
|
|
|
|
2020-12-27 19:41:35 +01:00
|
|
|
admin:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/admin:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "admin_data:/data"
|
|
|
|
- "dkim:/dkim"
|
2020-12-27 19:41:35 +01:00
|
|
|
depends_on:
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
2020-12-28 20:32:48 +01:00
|
|
|
- front
|
2023-04-15 13:24:21 +02:00
|
|
|
- redis
|
2023-05-23 00:01:22 +02:00
|
|
|
- database
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-05-23 00:01:22 +02:00
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2020-12-27 19:41:35 +01:00
|
|
|
imap:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/dovecot:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "dovecot_mail:/mail"
|
2023-04-15 19:48:46 +02:00
|
|
|
- "/etc/mailu/overrides:/overrides:ro"
|
2020-12-27 19:41:35 +01:00
|
|
|
depends_on:
|
|
|
|
- front
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2021-08-22 20:42:03 +02:00
|
|
|
|
2020-12-27 19:41:35 +01:00
|
|
|
smtp:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/postfix:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2023-04-15 19:48:46 +02:00
|
|
|
- "/etc/mailu/overrides:/overrides:ro"
|
2020-12-28 20:32:48 +01:00
|
|
|
- "smtp_queue:/queue"
|
2020-12-27 19:41:35 +01:00
|
|
|
depends_on:
|
|
|
|
- front
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2020-12-27 19:41:35 +01:00
|
|
|
|
2023-04-15 19:48:46 +02:00
|
|
|
oletools:
|
|
|
|
image: ghcr.io/mailu/oletools:{{mailu_version}}
|
|
|
|
hostname: oletools
|
|
|
|
restart: always
|
2023-05-23 00:01:22 +02:00
|
|
|
depends_on:
|
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
|
|
|
networks:
|
|
|
|
- noinet
|
2023-04-15 19:48:46 +02:00
|
|
|
|
2020-12-27 19:41:35 +01:00
|
|
|
antispam:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/rspamd:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "filter:/var/lib/rspamd"
|
|
|
|
- "dkim:/dkim"
|
2023-04-15 19:48:46 +02:00
|
|
|
- "/etc/mailu/overrides/rspamd:/overrides:ro"
|
2020-12-27 19:41:35 +01:00
|
|
|
depends_on:
|
|
|
|
- front
|
2023-04-15 13:24:21 +02:00
|
|
|
- redis
|
|
|
|
- antivirus
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
|
|
|
networks:
|
|
|
|
- default
|
|
|
|
- noinet
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2020-12-27 19:41:35 +01:00
|
|
|
|
|
|
|
# Optional services
|
|
|
|
antivirus:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/clamav:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "filter:/data"
|
2023-05-23 00:01:22 +02:00
|
|
|
depends_on:
|
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2020-12-27 19:41:35 +01:00
|
|
|
|
|
|
|
webdav:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/radicale:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "webdav_data:/data"
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-05-23 00:01:22 +02:00
|
|
|
networks:
|
|
|
|
- radicale
|
|
|
|
depends_on:
|
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2020-12-27 19:41:35 +01:00
|
|
|
|
2022-02-11 12:49:41 +01:00
|
|
|
fetchmail:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/fetchmail:{{mailu_version}}
|
|
|
|
volumes:
|
|
|
|
- "admin_data:/data"
|
2022-02-11 12:49:41 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-04-15 19:48:46 +02:00
|
|
|
depends_on:
|
|
|
|
- admin
|
|
|
|
- smtp
|
|
|
|
- imap
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
2020-12-27 19:41:35 +01:00
|
|
|
|
|
|
|
webmail:
|
2023-04-15 19:48:46 +02:00
|
|
|
image: ghcr.io/mailu/webmail:{{mailu_version}}
|
2020-12-27 19:41:35 +01:00
|
|
|
restart: always
|
|
|
|
env_file: mailu.env
|
|
|
|
volumes:
|
2020-12-28 20:54:44 +01:00
|
|
|
- "webmail_data:/data"
|
2023-12-13 14:42:13 +01:00
|
|
|
- "/etc/mailu/overrides:/overrides:ro"
|
2020-12-27 19:41:35 +01:00
|
|
|
depends_on:
|
|
|
|
- imap
|
2023-04-15 19:48:46 +02:00
|
|
|
- front
|
2023-05-23 00:01:22 +02:00
|
|
|
- resolver
|
2022-01-29 19:21:46 +01:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-05-23 00:01:22 +02:00
|
|
|
networks:
|
|
|
|
- webmail
|
|
|
|
dns:
|
|
|
|
- 192.168.203.254
|
|
|
|
|
2020-12-28 17:24:45 +01:00
|
|
|
volumes:
|
|
|
|
database:
|
2020-12-28 20:32:48 +01:00
|
|
|
smtp_queue:
|
2020-12-28 20:54:44 +01:00
|
|
|
admin_data:
|
|
|
|
webdav_data:
|
|
|
|
webmail_data:
|
|
|
|
filter:
|
|
|
|
dkim:
|
|
|
|
dovecot_mail:
|
|
|
|
redis_data:
|
2020-12-27 19:41:35 +01:00
|
|
|
networks:
|
|
|
|
default:
|
|
|
|
driver: bridge
|
|
|
|
ipam:
|
|
|
|
driver: default
|
|
|
|
config:
|
2020-12-27 23:14:11 +01:00
|
|
|
- subnet: {{mailu_subnet}}
|
2023-05-23 00:01:22 +02:00
|
|
|
radicale:
|
|
|
|
driver: bridge
|
|
|
|
webmail:
|
|
|
|
driver: bridge
|
|
|
|
noinet:
|
|
|
|
driver: bridge
|
|
|
|
internal: true
|