SynCD_base_FLUX / Dockerfile
tri86uit's picture
Create Dockerfile
ea89a29 verified
raw
history blame contribute delete
714 Bytes
# Sử dụng Python 3.10 (Phiên bản ổn định cho code cũ)
FROM python:3.10-slim
# Cài đặt các công cụ hệ thống cần thiết
RUN apt-get update && apt-get install -y \
git \
git-lfs \
ffmpeg \
libsm6 \
libxext6 \
cmake \
rsync \
libgl1 \
&& rm -rf /var/lib/apt/lists/* \
&& git lfs install
# Thiết lập thư mục làm việc
WORKDIR /app
# Copy file requirements và cài đặt thư viện
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy toàn bộ code vào Space
COPY . .
# Cấp quyền truy cập (fix lỗi permission trên HF Spaces)
RUN chmod -R 777 /app
# Chạy ứng dụng
CMD ["python", "app.py"]