|
|
|
FROM python:3.10-slim |
|
|
|
LABEL maintainer="Your Name <your.email@example.com>" |
|
LABEL description="Multi-modal server with LLM, Stable Diffusion, Whisper, and model downloading." |
|
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive \ |
|
PIP_NO_CACHE_DIR=off \ |
|
PIP_DISABLE_PIP_VERSION_CHECK=on \ |
|
PYTHONUNBUFFERED=1 \ |
|
|
|
CMAKE_ARGS="-DCMAKE_POLICY_VERSION_MINIMUM=3.5" \ |
|
|
|
MODELS_BASE_DIR=/app/models \ |
|
|
|
|
|
LLM_MODEL_REPO="tensorblock/xddd-GGUF" \ |
|
LLM_MODEL_FILE="xddd-Q2_K.gguf" \ |
|
SD_MODEL_REPO="city96/FLUX.1-schnell-gguf" \ |
|
SD_MODEL_FILE="flux1-schnell-Q8_0.gguf" \ |
|
SD_REFINER_MODEL_REPO="gpustack/stable-diffusion-xl-refiner-1.0-GGUF" \ |
|
SD_REFINER_MODEL_FILE="stable-diffusion-xl-refiner-1.0-Q8_0.gguf" \ |
|
WHISPER_MODEL_REPO="ggerganov/whisper.cpp" \ |
|
WHISPER_MODEL_FILE="ggml-base.en.bin" \ |
|
VIDEO_MODEL_REPO="city96/Wan2.1-I2V-14B-720P-gguf" \ |
|
VIDEO_MODEL_FILE="wan2.1-i2v-14b-720p-Q8_0.gguf" |
|
|
|
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \ |
|
build-essential \ |
|
cmake \ |
|
git \ |
|
git-lfs \ |
|
&& apt-get clean \ |
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
|
|
WORKDIR /app |
|
|
|
|
|
COPY requirements.txt . |
|
|
|
|
|
|
|
RUN pip install --no-cache-dir -r requirements.txt |
|
|
|
|
|
COPY app.py . |
|
|
|
|
|
RUN mkdir -p ${MODELS_BASE_DIR}/llm \ |
|
${MODELS_BASE_DIR}/sd \ |
|
${MODELS_BASE_DIR}/sd_refiner \ |
|
${MODELS_BASE_DIR}/whisper \ |
|
${MODELS_BASE_DIR}/video |
|
|
|
|
|
|
|
|
|
|
|
|
|
EXPOSE 7860 |
|
|
|
|
|
CMD ["python", "app.py"] |