File size: 607 Bytes
4b30af2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
FROM ubuntu:22.04

RUN apt-get update && \
    apt-get install -y \
    build-essential \
    libssl-dev \
    zlib1g-dev \
    libopenblas-dev \
    libomp-dev \
    cmake \
    pkg-config \
    git \
    python3-pip \
    curl \
    libcurl4-openssl-dev \
    wget && \
    rm -rf /var/lib/apt/lists/*

RUN pip3 install --upgrade pip && \
    pip3 install openai fastapi uvicorn pydantic orjson httptools

RUN pip install httpx[http2]

COPY main_server.py /main_server.py

EXPOSE 7860

CMD ["python3", "-m", "uvicorn", "main_server:app", "--host", "0.0.0.0", "--port", "7860"]