FROM python:3.11-slim ENV PYTHONDONTWRITEBYTECODE=1 ENV PYTHONUNBUFFERED=1 WORKDIR /app RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential \ curl \ protobuf-compiler \ && rm -rf /var/lib/apt/lists/* RUN pip install --no-cache-dir --upgrade pip RUN pip install --no-cache-dir \ langchain==0.1.0 \ langchain-community==0.0.10 \ langchain-elasticsearch \ grpcio \ grpcio-tools \ grpcio-reflection \ pydantic COPY ./protos ./protos COPY . . RUN python -m grpc_tools.protoc \ --proto_path=./protos \ --python_out=./src \ --grpc_python_out=./src \ ./protos/brunix.proto EXPOSE 50051 CMD ["python", "src/server.py"]