-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
259 lines (246 loc) · 4.9 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
name: mailu
services:
# External dependencies
redis:
image: redis:alpine
restart: always
volumes:
- "/data/redis:/data"
depends_on:
- resolver
dns:
- 10.1.1.254
# Core services
front:
image: ghcr.io/mailu/nginx:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-front
ports:
- "25:25"
- "465:465"
- "587:587"
- "110:110"
- "995:995"
- "143:143"
- "993:993"
- "4190:4190"
- "172.17.0.1:59000:443"
networks:
- default
- webmail
- radicale
volumes:
- "/data/certs:/certs"
- "/data/overrides/nginx:/overrides:ro"
depends_on:
- resolver
dns:
- 10.1.1.254
resolver:
image: ghcr.io/mailu/unbound:latest
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-resolver
restart: always
networks:
default:
ipv4_address: 10.1.1.254
admin:
image: ghcr.io/mailu/admin:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-admin
volumes:
- "/data/data:/data"
- "/data/dkim:/dkim"
depends_on:
- redis
- resolver
dns:
- 10.1.1.254
imap:
image: ghcr.io/mailu/dovecot:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-imap
volumes:
- "/data/mail:/mail"
- "/data/overrides/dovecot:/overrides:ro"
networks:
- default
- fts_attachments
depends_on:
- front
- fts_attachments
- resolver
dns:
- 10.1.1.254
smtp:
image: ghcr.io/mailu/postfix:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-smtp
volumes:
- "/data/mailqueue:/queue"
- "/data/overrides/postfix:/overrides:ro"
depends_on:
- front
- resolver
dns:
- 10.1.1.254
oletools:
image: ghcr.io/mailu/oletools:latest
hostname: oletools
logging:
driver: journald
options:
tag: mailu-oletools
restart: always
networks:
- oletools
depends_on:
- resolver
dns:
- 10.1.1.254
fts_attachments:
image: apache/tika:2.9.2.1-full
hostname: tika
logging:
driver: journald
options:
tag: mailu-tika
restart: always
networks:
- fts_attachments
depends_on:
- resolver
dns:
- 10.1.1.254
healthcheck:
test: ["CMD-SHELL", "wget -nv -t1 -O /dev/null http://127.0.0.1:9998/tika || exit 1"]
interval: 10s
timeout: 5s
retries: 3
start_period: 10s
antispam:
image: ghcr.io/mailu/rspamd:latest
hostname: antispam
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-antispam
networks:
- default
- oletools
- clamav
volumes:
- "/data/filter:/var/lib/rspamd"
- "/data/overrides/rspamd:/overrides:ro"
depends_on:
- front
- redis
- oletools
- antivirus
- resolver
dns:
- 10.1.1.254
# Optional services
antivirus:
image: clamav/clamav-debian:1.2.3-45
restart: always
logging:
driver: journald
options:
tag: mailu-antivirus
networks:
- clamav
volumes:
- "/data/filter/clamav:/var/lib/clamav"
healthcheck:
test: ["CMD-SHELL", "kill -0 `cat /tmp/clamd.pid` && kill -0 `cat /tmp/freshclam.pid`"]
interval: 10s
timeout: 5s
retries: 3
start_period: 10s
webdav:
image: ghcr.io/mailu/radicale:latest
restart: always
logging:
driver: journald
options:
tag: mailu-webdav
volumes:
- "/data/dav:/data"
networks:
- radicale
fetchmail:
image: ghcr.io/mailu/fetchmail:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-fetchmail
volumes:
- "/data/data/fetchmail:/data"
depends_on:
- admin
- smtp
- imap
- resolver
dns:
- 10.1.1.254
# Webmail
webmail:
image: ghcr.io/mailu/webmail:latest
restart: always
env_file: mailu.env
logging:
driver: journald
options:
tag: mailu-webmail
volumes:
- "/data/webmail:/data"
- "/data/overrides/snappymail:/overrides:ro"
networks:
- webmail
depends_on:
- front
networks:
default:
enable_ipv6: true
driver: bridge
ipam:
driver: default
config:
- subnet: 10.1.1.0/24
- subnet: fdab:03bb:c928:beef::/64
radicale:
driver: bridge
webmail:
driver: bridge
clamav:
driver: bridge
oletools:
driver: bridge
internal: true
fts_attachments:
driver: bridge
internal: true