-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
44 lines (42 loc) · 1.28 KB
/
docker-compose.yml
File metadata and controls
44 lines (42 loc) · 1.28 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
services:
app:
build:
context: .
target: app
env_file: .env
volumes:
- analytics_data:/data
environment:
# Required: generate with `openssl rand -base64 32`
STRATIFIO_ENCRYPTION_KEY: '${STRATIFIO_ENCRYPTION_KEY:?Set STRATIFIO_ENCRYPTION_KEY (generate with: openssl rand -base64 32)}'
STRATIFIO_PRODUCT_DB_URL: 'sqlite+aiosqlite:////data/stratifio_product.db'
# Optional API key — leave empty for local exploration
STRATIFIO_API_KEY: ${STRATIFIO_API_KEY:-}
STRATIFIO_CORS_ORIGINS: ${STRATIFIO_CORS_ORIGINS:-http://localhost:9999}
STRATIFIO_DEBUG: ${STRATIFIO_DEBUG:-false}
STRATIFIO_LOG_LEVEL: ${STRATIFIO_LOG_LEVEL:-INFO}
STRATIFIO_LOG_FORMAT: ${STRATIFIO_LOG_FORMAT:-json}
STRATIFIO_LOG_SQL: ${STRATIFIO_LOG_SQL:-false}
healthcheck:
test:
[
'CMD-SHELL',
'python -c "import urllib.request; urllib.request.urlopen(''http://localhost:8000/'')"',
]
interval: 15s
timeout: 5s
retries: 5
start_period: 90s
restart: unless-stopped
caddy:
build:
context: .
target: caddy-server
ports:
- '9999:80'
depends_on:
app:
condition: service_healthy
restart: unless-stopped
volumes:
analytics_data: