File size: 695 Bytes
d6cf579
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Python සහ CUDA සහිත පදනමක් භාවිතා කිරීම
FROM nvidia/cuda:12.1.0-runtime-ubuntu22.04

# Python ස්ථාපනය
RUN apt-get update && apt-get install -y python3-pip python3-dev

# වැඩ කරන ස්ථානය සැකසීම
WORKDIR /app

# Requirements copy කර ස්ථාපනය කිරීම
COPY requirements.txt .
RUN pip3 install --no-cache-dir -r requirements.txt

# සියලුම code ගොනු copy කිරීම
COPY . .

# FastAPI port එක විවෘත කිරීම
EXPOSE 7860

# Server එක පණ ගැන්වීම
CMD ["uvicorn", "app:main", "--host", "0.0.0.0", "--port", "7860"]