From 9b6b3e90278d3d4acd393362aafc16ca1eb69295 Mon Sep 17 00:00:00 2001 From: nexy7574 Date: Wed, 5 Jun 2024 01:23:39 +0100 Subject: [PATCH] Fix IPC --- docker-compose.yml | 6 +++--- src/server.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index c1400ab..dbb10db 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -9,7 +9,7 @@ services: - ./jimmy.log:/app/jimmy.log - /dev/dri:/dev/dri - jimmy-data:/app/data - - ./ipc:/tmp/college-bot-ipc + - ./ipc/:/tmp/ipc/ extra_hosts: - host.docker.internal:host-gateway depends_on: @@ -19,10 +19,10 @@ services: image: git.i-am.nexus/nex/college-bot:latest restart: unless-stopped volumes: - - ./ipc:/tmp/college-bot-ipc + - ./ipc/:/tmp/ipc/ depends_on: - jimmy - command: ["python", "server.py"] + command: ["/app/venv/bin/uvicorn", "--host", "0.0.0.0", "--port", "1111", "server:app"] ollama: image: ollama/ollama:latest container_name: ollama diff --git a/src/server.py b/src/server.py index 7667617..9be8833 100644 --- a/src/server.py +++ b/src/server.py @@ -12,7 +12,7 @@ from fastapi.responses import JSONResponse from fastapi.security import HTTPBasic, HTTPBasicCredentials from pydantic import BaseModel, Field, ValidationError -FIFO = "/tmp/college-bot-ipc" +FIFO = "/tmp/ipc/ipc.socket" JSON: typing.Union[ str, int, float, bool, None, typing.Dict[str, "JSON"], typing.List["JSON"] ] = typing.Union[