-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
113 lines (107 loc) · 2.93 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
version: '3.8'
services:
mongodb:
image: imteksim/mongod-on-smb:${MONGOD_ON_SMB_CONTAINER_IMAGE_VERSION}
restart: always
privileged: true
cap_add:
- SYS_ADMIN
depends_on:
- sambaserver-db
ports:
- "27017:27017"
environment:
MONGO_INITDB_ROOT_USERNAME_FILE: /run/secrets/username
MONGO_INITDB_ROOT_PASSWORD_FILE: /run/secrets/password
SMB_HOST: sambaserver-db
SMB_SHARE: sambashare
TZ: Europe/Berlin
command: --config /etc/mongod.conf
security_opt:
- label=disable
secrets:
- source: mongodb_username
target: username
- source: mongodb_password
target: password
- source: mongodb_tls_key
target: tls_key.pem
- source: mongodb_tls_cert
target: tls_cert.pem
- source: mongodb_tls_key_cert
target: tls_key_cert.pem
- source: root_ca
target: rootCA.pem
- source: smb_credentials_db
target: smb-credentials
mongodb-backup:
image: imteksim/mongodb-backup:${MONGODB_BACKUP_CONTAINER_IMAGE_VERSION}
restart: always
privileged: true
cap_add:
- SYS_ADMIN
depends_on:
- mongodb
- sambaserver-backup
environment:
SMB_HOST: sambaserver-backup
SMB_SHARE: sambashare
TZ: Europe/Berlin
security_opt:
- label=disable
secrets:
- source: mongodb_username
target: username
- source: mongodb_password
target: password
- source: mongodb_backup_tls_key
target: tls_key.pem
- source: mongodb_backup_tls_cert
target: tls_cert.pem
- source: mongodb_backup_tls_key_cert
target: tls_key_cert.pem
- source: root_ca
target: rootCA.pem
- source: smb_credentials_backup
target: smb-credentials
sambaserver-db:
image: dperson/samba:${SAMBA_CONTAINER_IMAGE_VERSION}
restart: always
command: -p -S -w WORKGROUP -s sambashare;/share;yes;no;yes
expose:
- "139"
- "445"
ports:
- "4445:445"
sambaserver-backup:
image: dperson/samba:${SAMBA_CONTAINER_IMAGE_VERSION}
restart: always
command: -p -S -w WORKGROUP -s sambashare;/share;yes;no;yes
expose:
- "139"
- "445"
ports:
- "5445:445"
secrets:
smb_credentials_db:
file: secrets/mongodb/smb-credentials
smb_credentials_backup:
file: secrets/mongodb_backup/smb-credentials
mongodb_username:
file: secrets/mongodb/username
mongodb_password:
file: secrets/mongodb/password
mongodb_tls_key:
file: secrets/mongodb/tls_key.pem
mongodb_tls_cert:
file: secrets/mongodb/tls_cert.pem
mongodb_tls_key_cert:
file: secrets/mongodb/tls_key_cert.pem
mongodb_backup_tls_key:
file: secrets/mongodb_backup/tls_key.pem
mongodb_backup_tls_cert:
file: secrets/mongodb_backup/tls_cert.pem
mongodb_backup_tls_key_cert:
file: secrets/mongodb_backup/tls_key_cert.pem
root_ca:
file: secrets/rootCA.pem