Spaces:
Sleeping
Sleeping
File size: 697 Bytes
3fe0be9 9c54070 3fe0be9 | 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 30 31 32 33 | FROM python:3.9-slim
# ์์คํ
์์กด์ฑ ์ค์น
RUN apt-get update && apt-get install -y \
git \
ffmpeg \
libsndfile1 \
libasound2-dev \
&& rm -rf /var/lib/apt/lists/*
# ์์
๋๋ ํ ๋ฆฌ ์ค์
WORKDIR /app
# ์บ์ ๋๋ ํ ๋ฆฌ ์์ฑ ๋ฐ ํผ๋ฏธ์
๋ถ์ฌ
RUN mkdir -p /app/cache && chmod -R 777 /app/cache
# ์บ์ ํ๊ฒฝ ๋ณ์ ์ค์
ENV HF_HOME=/app/cache
ENV TRANSFORMERS_CACHE=/app/cache
ENV HUGGINGFACE_HUB_CACHE=/app/cache
# requirements.txt ์ค์น
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# ์์ค ๋ณต์ฌ
COPY . .
# ํฌํธ ๋
ธ์ถ
EXPOSE 7860
# ์ฑ ์คํ
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"] |