-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathdocker-compose.yml
251 lines (230 loc) · 8.37 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
# vim: syntax=yaml textwidth=120 expandtab tabstop=2 softtabstop=2 shiftwidth=2 autoindent
# Docker compose file for a full-featured Linshare architecture
version: '3.7'
services:
reverse-proxy:
image: traefik:v2.6
container_name: linshare_reverse-proxy
ports:
- 443:443
labels:
- "traefik.enable=true"
- "traefik.http.routers.traefik.rule=Host(`traefik.linshare.local`)"
- "traefik.http.services.traefik.loadbalancer.server.port=8080"
volumes:
- ./conf/traefik:/etc/traefik
- ./ssl/:/ssl/
docker-socket:
container_name: linshare_docker-socket
image: tecnativa/docker-socket-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
- CONTAINERS=1
database:
container_name: linshare_database
restart: on-failure
image: linagora/linshare-database:6.3.0
volumes:
- ./data/postgres_data/lib:/var/lib/postgresql/data
environment:
- PGDATA=/var/lib/postgresql/data/pgdata
- POSTGRES_USER=linshare
- POSTGRES_PASSWORD=linshare
backend:
container_name: linshare_backend
restart: on-failure
image: linagora/linshare-backend:6.3.0
links:
- database:linshare_database
- mongodb:linshare_mongodb
- thumbnail-server:linshare_thumbnail-server
depends_on:
- database
- mongodb
- thumbnail-server
volumes:
- ./data/linshare_data/lib:/var/lib/linshare
- ./conf/catalina.properties:/usr/local/tomcat/conf/catalina.properties
- ./conf/log4j.properties:/etc/linshare/log4j.properties
healthcheck:
test: ["CMD", "curl", "-s", "-f", "http://localhost:8080/linshare/"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
environment:
# These variables are mandatory
- SMTP_HOST=linshare_mail
- SMTP_PORT=25
- CLAMAV_HOST=linshare_clamav
- POSTGRES_HOST=linshare_database
- POSTGRES_PORT=5432
- POSTGRES_USER=linshare
- POSTGRES_PASSWORD=linshare
- CLAMAV_PORT=3310
- MONGODB_DATA_REPLICA_SET=linshare_mongodb:27017
- MONGODB_SMALLFILES_REPLICA_SET=linshare_mongodb:27017
- MONGODB_USER=linshare
- MONGODB_PASSWORD=linshare
- THUMBNAIL_ENABLE=true
# - THUMBNAIL_HOST=thumbnail-server
# - THUMBNAIL_PORT=8080
# Default variables can be overriden if needed.
#- SMTP_USER=<undefined>
#- SMTP_PASSWORD=<undefined>
#- CLAMAV_PORT=3310
#- POSTGRES_PORT=5432
thumbnail-server:
container_name: linshare_thumbnail-server
restart: on-failure
image: linagora/linshare-thumbnail-server:2.1.1
healthcheck:
test: ["CMD", "curl", "-s", "-f", "http://localhost:8081/healthcheck"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s
home:
container_name: linshare_home
restart: on-failure
image: httpd:2.4
volumes:
- ./conf/home:/usr/local/apache2/htdocs/
- ./README.md:/usr/local/apache2/htdocs/md/README.md
labels:
- "traefik.enable=true"
- "traefik.http.routers.home.rule=Host(`home.linshare.local`)"
ui-user:
container_name: linshare_ui-user
restart: on-failure
image: linagora/linshare-ui-user:6.3.0
healthcheck:
test: ["CMD", "curl", "-s", "-f", "http://localhost/linshare/"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
depends_on:
- backend
labels:
- "traefik.enable=true"
- "traefik.http.routers.user.rule=Host(`user.linshare.local`)"
environment:
- EXTERNAL_URL=user.linshare.local
- TOMCAT_URL=backend
- TOMCAT_PORT=8080
ui-admin:
container_name: linshare_ui-admin
restart: on-failure
image: linagora/linshare-ui-admin:6.3.0
healthcheck:
test: ["CMD", "curl", "-s", "-f", "http://localhost/linshare/"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
depends_on:
- backend
labels:
- "traefik.enable=true"
- "traefik.http.routers.admin.rule=Host(`admin.linshare.local`)"
environment:
- EXTERNAL_URL=admin.linshare.local
- TOMCAT_URL=backend
- TOMCAT_PORT=8080
ui-upload-request:
container_name: linshare_ui-upload-request
image: linagora/linshare-ui-upload-request:6.3.0
environment:
- EXTERNAL_URL=upload-request.linshare.local
- TOMCAT_URL=backend
- TOMCAT_PORT=8080
labels:
- "traefik.enable=true"
- "traefik.http.routers.uploadrequest.rule=Host(`upload-request.linshare.local`)"
mail:
container_name: linshare_mail
image: docker.io/mailserver/docker-mailserver:10.5
hostname: mail
domainname: linshare.org
volumes:
- /var/mail
- /var/mail-state
- /var/log/mail/
- /tmp/docker-mailserver/
- /etc/localtime:/etc/localtime:ro
- ./conf/mail_conf/main.cf:/etc/postfix/main.cf
environment:
- ENABLE_SPAMASSASSIN=0
- SPAMASSASSIN_SPAM_TO_INBOX=0
- ENABLE_POSTGREY=0
- DMS_DEBUG=1
- ENABLE_CLAMAV=0
- ENABLE_FAIL2BAN=0
- ONE_DIR=1
- DMS_DEBUG=0
- ENABLE_LDAP=1
- LDAP_SERVER_HOST=ldap://ldap:1389
- LDAP_SEARCH_BASE=ou=People,dc=linshare,dc=org
- LDAP_BIND_DN=cn=linshare,dc=linshare,dc=org
- LDAP_BIND_PW=linshare
- LDAP_QUERY_FILTER_DOMAIN=(&(|(mail=*@%s)(mailalias=*@%s)(mailGroupMember=*@%s))(mailEnabled=TRUE))
- LDAP_QUERY_FILTER_USER=(&(mail=%s)(mailEnabled=TRUE))
- LDAP_QUERY_FILTER_ALIAS=(&(mailAlias=%s)(mailEnabled=TRUE))
- LDAP_QUERY_FILTER_GROUP=(&(mailGroupMember=%s)(mailEnabled=TRUE))
- DOVECOT_AUTH_BIND=yes
- DOVECOT_USER_FILTER=(&(objectClass=PostfixBookMailAccount)(uid=%n))
- DOVECOT_USER_ATTRS=mailHomeDirectory=home,mailUidNumber=uid,mailGidNumber=gid,mailStorageDirectory=mail
- DOVECOT_PASS_FILTER=(&(objectClass=PostfixBookMailAccount)(uid=%n))
- DOVECOT_PASS_ATTRS=uid=user,userPassword=password
webmail:
container_name: linshare_webmail
image: robbertkl/roundcube
volumes:
- ./conf/webmail_conf/config.inc.php:/var/www/config/config.inc.php
environment:
- ROUNDCUBE_DEFAULT_HOST=linshare_mail
- ROUNDCUBE_SMTP_SERVER=linshare_mail
- ROUNDCUBE_SMTP_PORT=25
labels:
- "traefik.enable=true"
- "traefik.http.routers.webmail.rule=Host(`webmail.linshare.local`)"
documentation:
container_name: linshare_documentation
image: linagora/linshare-backend-documentation-webservice:6.3.0
labels:
- "traefik.enable=true"
- "traefik.http.routers.docs.rule=Host(`docs.linshare.local`)"
- "traefik.http.services.docs.loadbalancer.server.port=8080"
clamav:
container_name: linshare_clamav
restart: on-failure
image: mkodockx/docker-clamav
mongodb:
container_name: linshare_mongodb
restart: on-failure
image: mongo:4.2
environment:
- MONGO_INITDB_ROOT_USERNAME=linshare
- MONGO_INITDB_ROOT_PASSWORD=linshare
volumes:
- ./data/mongodb_data/db:/data/db
ldap:
image: linagora/linshare-ldap-for-tests:2.0
container_name: linshare_ldap
ports:
- "1389:1389"
init:
image: linagora/linshare-init:6.3.0
container_name: linshare_init
environment:
- LS_SERVER_HOST=backend
- LS_SERVER_PORT=8080
- LS_LDAP_NAME=ldap
- LS_LDAP_URL=ldap://ldap:1389
- LS_LDAP_BASE_DN=ou=People,dc=linshare,dc=org
- LS_LDAP_DN=cn=linshare,dc=linshare,dc=org
- LS_LDAP_PW=linshare
- LS_DOMAIN_PATTERN_NAME=pattern-demo
- LS_DOMAIN_PATTERN_MODEL=a4620dfc-dc46-11e8-a098-2355f9d6585a