-
-
Notifications
You must be signed in to change notification settings - Fork 254
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
55 lines (53 loc) · 1.42 KB
/
Copy pathdocker-compose.yml
File metadata and controls
55 lines (53 loc) · 1.42 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
services:
app:
# build:
# context: .
# dockerfile: docker/Dockerfile
# target: aio
image: ghcr.io/seanmorley15/adventurelog:latest
container_name: adventurelog
restart: unless-stopped
env_file: .env
environment:
SITE_URL: ${SITE_URL:-http://localhost:8015}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Set POSTGRES_PASSWORD in .env or your environment}
PGHOST: db
POSTGRES_DB: database
POSTGRES_USER: adventure
PORT: "3000"
ports:
- "${HOST_PORT:-8015}:80"
volumes:
- adventurelog_media:/code/media/
depends_on:
db:
condition: service_healthy
healthcheck:
test:
[
"CMD-SHELL",
"python3 -c \"import urllib.request; urllib.request.urlopen('http://127.0.0.1:80/health')\""
]
interval: 30s
timeout: 5s
retries: 5
start_period: 120s
db:
image: postgis/postgis:16-3.5
container_name: adventurelog-db
restart: unless-stopped
environment:
POSTGRES_DB: database
POSTGRES_USER: adventure
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Set POSTGRES_PASSWORD in .env or your environment}
volumes:
- postgres_data:/var/lib/postgresql/data/
healthcheck:
test: ["CMD-SHELL", "pg_isready -U adventure -d database"]
interval: 5s
timeout: 5s
retries: 5
start_period: 10s
volumes:
postgres_data:
adventurelog_media: