mirror of
https://github.com/furyhawk/lta_datamall_api.git
synced 2026-07-20 09:48:00 +00:00
27 lines
692 B
YAML
27 lines
692 B
YAML
services:
|
|
valkey:
|
|
image: valkey/valkey:8-alpine
|
|
command: ["valkey-server", "--save", "", "--appendonly", "no"]
|
|
ports:
|
|
- "6379:6379"
|
|
restart: unless-stopped
|
|
|
|
api:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
image: lta-datamall-bus-backend:latest
|
|
env_file:
|
|
- .env
|
|
depends_on:
|
|
- valkey
|
|
ports:
|
|
- "${APP_PORT:-8000}:${APP_PORT:-8000}"
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import os, urllib.request; urllib.request.urlopen(f'http://localhost:{os.getenv(\"APP_PORT\", \"8000\")}/healthz', timeout=3)"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
start_period: 10s
|
|
restart: unless-stopped
|