feat: single container image (nginx + backend), fix fresh DB init
- deploy/Dockerfile: unified image with supervisord (nginx + uvicorn) - distribution/docker-compose.single.yml: single container option - distribution/README.md: 3 deployment options (single, compose, docker run) - Fix: add status column to chat_messages CREATE TABLE (was only in migration, broke fresh DB) - push-images.sh: builds 3 images (unified, backend, frontend)
This commit is contained in:
31
distribution/docker-compose.single.yml
Normal file
31
distribution/docker-compose.single.yml
Normal file
@@ -0,0 +1,31 @@
|
||||
services:
|
||||
agent:
|
||||
image: ${OCIR_REGION}.ocir.io/${OCIR_NAMESPACE}/oci-cis-agent:${IMAGE_TAG:-latest}
|
||||
container_name: oci-cis-agent
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- APP_SECRET=${APP_SECRET:?Set APP_SECRET in .env (openssl rand -hex 64)}
|
||||
- JWT_EXPIRY_HOURS=${JWT_EXPIRY_HOURS:-12}
|
||||
- DATA_DIR=/data
|
||||
- CORS_ORIGINS=${CORS_ORIGINS:-}
|
||||
- TZ=${TZ:-America/Sao_Paulo}
|
||||
- OCI_CLI_SUPPRESS_FILE_PERMISSIONS_WARNING=True
|
||||
ports:
|
||||
- "${PORT:-8080}:8080"
|
||||
volumes:
|
||||
- agent-data:/data
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:8080/api/health"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
logging:
|
||||
driver: "json-file"
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
mem_limit: 4g
|
||||
|
||||
volumes:
|
||||
agent-data:
|
||||
driver: local
|
||||
Reference in New Issue
Block a user