Image based in Flux Kontextā installation.
You can create your own image bulding this Dockerfile:
# Usar imagen base de Python con CUDA
FROM nvidia/cuda:12.1.1-base-ubuntu22.04
ENV DEBIAN_FRONTEND=noninteractive
ENV CMDARGS --listen
ARG UID=1000
ARG GID=1000
# Instalar dependencias del sistema
RUN apt-get update && apt-get install -y \
python3.10 \
python3.10-venv \
python3-pip \
git \
wget \
curl \
libgl1-mesa-glx \
libglib2.0-0 \
libsm6 \
libxext6 \
libxrender-dev \
libgomp1
#&& rm -rf /var/lib/apt/lists/*
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
# Instala Node.js, que ahora incluye npm
RUN apt-get update && apt-get install -y nodejs
# Crear directorio de trabajo
WORKDIR /app
# Clonar el repositorio
RUN git clone https://github.com/ostris/ai-toolkit.git .
# Configurar variables de entorno para la instalación
ENV PYTHON_CMD=python3.10
ENV VENV_DIR=venv
RUN groupadd -g "${GID}" user && \
useradd -m -u "${UID}" -g "${GID}" user
RUN chown -R user:user /app
USER user
# Crear y activar entorno virtual
RUN python3.10 -m venv venv
# Instalar dependencias de Python
RUN . venv/bin/activate && \
pip install --upgrade pip && \
pip install --no-cache-dir torch==2.7.0 torchvision==0.22.0 torchaudio==2.7.0 --index-url https://download.pytorch.org/whl/cu126 && \
pip install -r requirements.txt
# Exponer el puerto por defecto
EXPOSE 8675
# Comando de inicio
CMD cd ui && npm run build_and_start
Content type
Image
Digest
sha256:102c272caā¦
Size
4.8 GB
Last updated
about 1 year ago
docker pull lliwi/flux-kontext