forked from moritzfl/docker-fiduswriter
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.example.yaml
More file actions
72 lines (66 loc) · 1.95 KB
/
docker-compose.example.yaml
File metadata and controls
72 lines (66 loc) · 1.95 KB
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
services:
web:
image: caddy:alpine
volumes:
- ./Caddyfile:/etc/caddy/Caddyfile
- ./static/collected:/app/static
networks: ['web','data']
depends_on: ['fiduswriter']
labels:
traefik.enable: true
traefik.http.routers.com-example-web.entrypoints: web
traefik.http.routers.com-example-web.rule: Host(`example.com`)
traefik.http.routers.com-example-web.middlewares: http-to-https
traefik.http.middlewares.http-to-https.redirectscheme.scheme: https
traefik.http.middlewares.http-to-https.redirectscheme.permanent: true
traefik.http.routers.com-example-web-secure.entrypoints: web-secure
traefik.http.routers.com-example-web-secure.rule: Host(`example.com`)
traefik.http.routers.com-example-web-secure.tls: true
traefik.http.routers.com-example-web-secure.tls.certresolver: letsencrypt
logging:
driver: 'json-file'
options:
max-size: '10m'
max-file: '3'
compress: 'true'
fiduswriter:
build: .
expose: ["8000"]
env_file: ["./env/fiduswriter.env"]
volumes:
- "./data:/data"
- "./static/transpile:/fiduswriter/static-transpile"
- "./static/libs:/fiduswriter/static-libs"
- "./static/collected:/fiduswriter/static-collected"
networks:
- data
depends_on:
postgres:
condition: service_healthy
logging:
driver: 'json-file'
options:
max-size: '10m'
max-file: '3'
compress: 'true'
postgres:
image: postgres:12-alpine
volumes: ["./data/postgres:/var/lib/postgresql/data"]
env_file: ["./env/postgres.env"]
networks: ["data"]
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER}"]
start_period: 20s
interval: 30s
retries: 5
timeout: 5s
logging:
driver: 'json-file'
options:
max-size: '10m'
max-file: '3'
compress: 'true'
networks:
data:
web:
external: true