-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose.yaml
199 lines (187 loc) · 4.49 KB
/
compose.yaml
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
services:
coredns:
image: coredns/coredns
container_name: dns.${DOMAIN}
restart: unless-stopped
expose:
- '53'
- '53/udp'
#ports:
# - '53:53'
# - '53:53/udp'
volumes:
- './services/coredns:/etc/coredns'
command: -conf /etc/coredns/Corefile
networks:
- backend
proxy:
image: nginxproxy/nginx-proxy
container_name: proxy.${DOMAIN}
restart: unless-stopped
environment:
- TRUST_DOWNSTREAM_PROXY=true
- ENABLE_IPV6=false
- DEFAULT_HOST=www.${DOMAIN}
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
- ./services/proxy/certs:/etc/nginx/certs
- ./services/proxy/vhost:/etc/nginx/vhost.d
- ./services/proxy/html:/usr/share/nginx/html
#- ./services/proxy/conf.d:/etc/nginx/conf.d
ports:
- '80:80'
- '443:443'
networks:
- backend
- frontend
# proxy-acme:
# image: nginxproxy/acme-companion
# container_name: proxy-acme.${DOMAIN}
# restart: always
# volumes:
# - /var/run/docker.sock:/var/run/docker.sock:ro
# - ./services/nginx/certs:/etc/nginx/certs
# - ./services/nginx/vhost:/etc/nginx/vhost.d
# - ./services/nginx/html:/usr/share/nginx/html
# - ./services/nginx/acme:/etc/acme.sh
# environment:
# - "[email protected]"
# - NGINX_PROXY_CONTAINER=proxy.${DOMAIN}
# depends_on:
# proxy:
# condition: service_started
# networks:
# - backend
postgres:
image: postgres:16
container_name: postgres.${DOMAIN}
restart: unless-stopped
secrets:
- db-password
shm_size: 128mb
environment:
- PGUSER=postgres
- POSTGRES_PASSWORD_FILE=/run/secrets/db-password
- PGDATA=/var/lib/postgresql/data/pgdata
volumes:
- db:/var/lib/postgresql/data
ports:
- '5432:5432'
healthcheck:
test: [ "CMD", "pg_isready" ]
interval: 10s
timeout: 5s
retries: 5
networks:
- backend
# adminer:
# image: adminer
# container_name: adminer.${DOMAIN}
# restart: unless-stopped
# environment:
# - ADMINER_DEFAULT_SERVER=postgres
# - ADMINER_DESIGN=nette
# - VIRTUAL_HOST=adminer.${DOMAIN}
# - LETSENCRYPT_HOST=adminer.${DOMAIN}
# ports:
# - 8080:8080
# depends_on:
# postgres:
# condition: service_healthy
# networks:
# - backend
redis:
image: redis:5
container_name: redis.${DOMAIN}
restart: unless-stopped
ports:
- '6379:6379'
networks:
- backend
guacd:
image: guacamole/guacd
container_name: guacd.${DOMAIN}
restart: unless-stopped
environment:
- GUACD_LOG_LEVEL=info
ports:
- 4822:4822
networks:
- backend
guacamole:
image: guacamole/guacamole
container_name: guacamole.${DOMAIN}
restart: unless-stopped
environment:
- POSTGRESQL_HOSTNAME=postgres
- POSTGRESQL_DATABASE=guacamole_db
- POSTGRESQL_USER=postgres
- POSTGRESQL_PASSWORD=development
- POSTGRESQL_PORT=5432
- GUACD_HOSTNAME=guacd
- GUACD_PORT=4822
- VIRTUAL_HOST=guacamole.${DOMAIN}
- LETSENCRYPT_HOST=guacamole.${DOMAIN}
ports:
- 8080:8080
depends_on:
postgres:
condition: service_healthy
guacd:
condition: service_healthy
networks:
- backend
inabox:
container_name: www.${DOMAIN}
image: gustaucastells/inabox
restart: unless-stopped
build:
context: .
dockerfile: services/inabox/Dockerfile
environment:
- DJANGO_DEBUG=False
- VIRTUAL_HOST=www.${DOMAIN}
- LETSENCRYPT_HOST=www.${DOMAIN}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
expose:
- '8000'
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_started
networks:
- backend
static:
container_name: static.${DOMAIN}
image: gustaucastells/static
restart: unless-stopped
build:
context: .
dockerfile: services/static/Dockerfile
environment:
- PORT=80
- SERVER_NAME=static.${DOMAIN}
- SERVER_ROOT=/var/www/html
- CONFIG_FILE=/etc/lighttpd/lighttpd.conf
- SKIP_HEALTHCHECK=false
- MAX_FDS=1024
- VIRTUAL_HOST=static.${DOMAIN}
expose:
- '80'
networks:
- backend
volumes:
db:
html:
slapd.d:
vhost:
secrets:
db-password:
file: db-password.txt
networks:
frontend:
driver: bridge
backend:
driver: bridge