ai-code-scanner-ui / docker-compose.yml
mubi-613's picture
Initial clean commit: Fixed security issues and removed heavy checkpoints
168ae1c
Raw
History Blame Contribute Delete
914 Bytes
version: '3.8'
services:
streamlit-app:
build: .
ports:
- "8501:8501"
environment:
- PYTHONUNBUFFERED=1
- TRANSFORMERS_CACHE=/app/.cache
volumes:
- ./models:/app/saved_model
- ./data:/app/data
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8501/_stcore/health"]
interval: 30s
timeout: 10s
retries: 3
api-backend:
build: .
ports:
- "8000:8000"
command: python api_backend.py
environment:
- PYTHONUNBUFFERED=1
volumes:
- ./models:/app/saved_model
restart: unless-stopped
# Optional: Add PostgreSQL for production
# db:
# image: postgres:13
# environment:
# POSTGRES_DB: codescanner
# POSTGRES_USER: admin
# POSTGRES_PASSWORD: secret
# volumes:
# - postgres_data:/var/lib/postgresql/data
volumes:
postgres_data: