Spaces:
Runtime error
Runtime error
File size: 710 Bytes
0c36a84 |
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 |
# Python 3.9 ์ฌ๋ฆผ ๋ฒ์ ์ฌ์ฉ
FROM python:3.9-slim
# ์์
๋๋ ํ ๋ฆฌ ์ค์
WORKDIR /app
# ์์คํ
ํจํค์ง ์
๋ฐ์ดํธ ๋ฐ ํ์ ๋ผ์ด๋ธ๋ฌ๋ฆฌ ์ค์น (ํ์์)
RUN apt-get update && apt-get install -y \
build-essential \
&& rm -rf /var/lib/apt/lists/*
# ์์กด์ฑ ํ์ผ ๋ณต์ฌ ๋ฐ ์ค์น
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# ์์ค ์ฝ๋ ๋ฐ ๋ฐ์ดํฐ ๋ณต์ฌ
COPY . .
# ๊ถํ ์ค์ (Hugging Face Spaces์์ ํ์ํ ์ ์์)
RUN chmod -R 777 /app
# ํฌํธ ์ค์ (Hugging Face Spaces ๊ธฐ๋ณธ ํฌํธ)
EXPOSE 7860
# ์๋ฒ ์คํ ๋ช
๋ น
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
|