-
Notifications
You must be signed in to change notification settings - Fork 5
/
docker-compose.yml
57 lines (50 loc) · 1.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
version: "3.10"
x-global-environment: &global
env_file:
- envs/.env # env file - NOT committed to Git
volumes:
- .:/app/
services:
# Caddy reverse proxy - web-facing SSL server
caddy:
<<: *global # this will inherit all the envs from x-global-environment
depends_on:
- django
image: caddy
ports:
- "80:80"
- "443:443"
restart: always
volumes:
- caddy-data:/data/
- caddy-data:/config/
- ./Caddyfile:/etc/caddy/Caddyfile
- ./staticdocs:/srv/staticdocs
# Django web application
django: &django
<<: *global # this will inherit all the envs from x-global-environment
build: .
image: e12-django:built # build image and save for use by other containers
depends_on:
- postgis
command: s/start-dev
restart: always
# PostgreSQL with PostGIS extension
postgis:
<<: *global # this will inherit config from x-global-environment
image: postgis/postgis:15-3.3
volumes:
- postgis-data:/var/lib/postgresql/data
restart: always
mkdocs:
<<: *global # this will inherit config from x-global-environment
image: e12-django:built
ports:
- 8001:8001
command: >
sh -c "mkdocs build --config-file documentation/mkdocs.yml &&
mkdocs serve --config-file documentation/mkdocs.yml"
restart: always
volumes:
caddy-data:
postgis-data: