diff --git a/Dockerfile b/Dockerfile index b372f6b..c55e6f1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -39,4 +39,4 @@ EXPOSE 8000 # Command to run the application using Uvicorn # The command format is: uvicorn [module:app_object] --host [ip] --port [port] # We use the standard uvicorn worker configuration -CMD ["python", "run.py"] +CMD ["uvicorn", "src.main:app", "--host", "0.0.0.0", "--port", "8000"] diff --git a/README.md b/README.md index bf4ffc7..58a4dbc 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ docker compose build docker compose up -d ``` -The API will be available at `http://localhost:8000`. +The API will be available at `http://localhost:8000`. The service runs with `uvicorn src.main:app --host 0.0.0.0 --port 8000`. Health check: ```bash diff --git a/docker-compose.yml b/docker-compose.yml index 9cf74ca..1a0e5f5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -11,6 +11,7 @@ services: - DATABASE_URL=postgresql://veritix:veritix@db:5432/veritix ports: - "8000:8000" + command: uvicorn src.main:app --host 0.0.0.0 --port 8000 depends_on: - db diff --git a/requirements.txt b/requirements.txt index 5f812e6..3f5b3a8 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,11 +1,14 @@ fastapi==0.115.0 uvicorn[standard]==0.30.6 -numpy==2.1.3 +numpy==1.26.4 scikit-learn==1.5.2 pydantic==2.8.2 httpx==0.28.1 pytest==8.4.2 +pytest-cov + pytest-cov==5.0.0 + requests==2.31.0 qrcode==7.4.2 Pillow==10.4.0 @@ -19,3 +22,6 @@ textblob==0.17.1 nltk==3.8.1 reportlab==4.0.7 +qrcode==7.4.2 + + diff --git a/src/utils.py b/src/utils.py index 0e4488f..0c762b0 100644 --- a/src/utils.py +++ b/src/utils.py @@ -5,7 +5,6 @@ from typing import Dict, Any from typing import Tuple -import json import os import hmac import hashlib