diff --git a/api/Dockerfile b/api/Dockerfile index 6245a8b..e1ae089 100644 --- a/api/Dockerfile +++ b/api/Dockerfile @@ -6,11 +6,13 @@ RUN apt-get update && apt-get install -y \ bash \ && rm -rf /var/lib/apt/lists/* -COPY . . +RUN pip install torch torchvision --index-url https://download.pytorch.org/whl/cpu + +COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt -RUN pip install torch torchvision --index-url https://download.pytorch.org/whl/cpu +Copy . . RUN chmod +x start_server.sh diff --git a/api/requirements.txt b/api/requirements.txt index 2c3121c..50c2cc4 100644 --- a/api/requirements.txt +++ b/api/requirements.txt @@ -3,4 +3,7 @@ networkx==3.6.1 numpy==2.3.4 tqdm==4.67.3 uvicorn==0.46.0 -python-multipart==0.0.27 \ No newline at end of file +python-multipart==0.0.27 +opencv-python==4.13.0.92 +pillow==12.2.0 +pycocotools==2.0.11 \ No newline at end of file diff --git a/compose.yaml b/compose.yaml index 3b7cb26..3cecf71 100644 --- a/compose.yaml +++ b/compose.yaml @@ -14,6 +14,8 @@ services: - cnn_website networks: - cnn_network + pull_policy: never + container_name: caddy_proxy cnn_api: @@ -25,6 +27,8 @@ services: restart: unless-stopped networks: - cnn_network + pull_policy: never + container_name: cnn_api cnn_website: @@ -36,6 +40,8 @@ services: restart: unless-stopped networks: - cnn_network + pull_policy: never + container_name: cnn_website networks: cnn_network: