mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-01-25 13:50:15 +08:00
update dockerfile
This commit is contained in:
parent
6ecb9e71f6
commit
3ff24f0985
10
.github/workflows/test.yml
vendored
10
.github/workflows/test.yml
vendored
@ -22,9 +22,15 @@ jobs:
|
|||||||
container: "nvcr.io/nvidia/pytorch:25.03-py3"
|
container: "nvcr.io/nvidia/pytorch:25.03-py3"
|
||||||
steps:
|
steps:
|
||||||
- run: |
|
- run: |
|
||||||
apt update || true
|
apt-get update
|
||||||
pip uninstall -y $(pip list --format=freeze | grep opencv)
|
apt-get install --no-install-recommends -y ffmpeg libsm6 libxext6
|
||||||
|
pip install uv && uv --version
|
||||||
|
apt-get purge -y
|
||||||
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
uv pip uninstall --system $(pip list --format=freeze | grep opencv)
|
||||||
rm -rf /usr/local/lib/python3.12/dist-packages/cv2/
|
rm -rf /usr/local/lib/python3.12/dist-packages/cv2/
|
||||||
|
uv pip install --no-build-isolation opencv-python-headless
|
||||||
name: Prepare Python
|
name: Prepare Python
|
||||||
- run: |
|
- run: |
|
||||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||||
|
|||||||
@ -17,14 +17,14 @@ ENV LC_ALL=C.UTF-8
|
|||||||
# mitigates
|
# mitigates
|
||||||
# RuntimeError: Failed to import transformers.generation.utils because of the following error (look up to see its traceback):
|
# RuntimeError: Failed to import transformers.generation.utils because of the following error (look up to see its traceback):
|
||||||
# numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject
|
# numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject
|
||||||
RUN echo "numpy<2" >> numpy-override.txt
|
RUN pip freeze | grep numpy > numpy-override.txt
|
||||||
|
|
||||||
# mitigates AttributeError: module 'cv2.dnn' has no attribute 'DictValue' \
|
# mitigates AttributeError: module 'cv2.dnn' has no attribute 'DictValue' \
|
||||||
# see https://github.com/facebookresearch/nougat/issues/40
|
# see https://github.com/facebookresearch/nougat/issues/40
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get install --no-install-recommends -y tzdata ffmpeg libsm6 libxext6 && \
|
apt-get install --no-install-recommends -y ffmpeg libsm6 libxext6 && \
|
||||||
pip install uv && uv --version && \
|
pip install uv && uv --version && \
|
||||||
apt-get purge -y --auto-remove tzdata && \
|
apt-get purge -y && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
RUN uv pip uninstall --system $(pip list --format=freeze | grep opencv) && \
|
RUN uv pip uninstall --system $(pip list --format=freeze | grep opencv) && \
|
||||||
|
|||||||
@ -9,21 +9,25 @@ ENV UV_BREAK_SYSTEM_PACKAGES=1
|
|||||||
ENV PIP_DISABLE_PIP_VERSION_CHECK=1
|
ENV PIP_DISABLE_PIP_VERSION_CHECK=1
|
||||||
ENV PIP_NO_CACHE_DIR=1
|
ENV PIP_NO_CACHE_DIR=1
|
||||||
ENV DEBIAN_FRONTEND=noninteractive
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
ENV LANG=C.UTF-8
|
ENV LANG=C.UTF-8
|
||||||
ENV LC_ALL=C.UTF-8
|
ENV LC_ALL=C.UTF-8
|
||||||
|
|
||||||
# - ffmpeg and CV2 dependencies are for media handling.
|
RUN pip freeze | grep numpy > numpy-override.txt
|
||||||
|
|
||||||
# mitigates AttributeError: module 'cv2.dnn' has no attribute 'DictValue' \
|
# mitigates AttributeError: module 'cv2.dnn' has no attribute 'DictValue' \
|
||||||
# see https://github.com/facebookresearch/nougat/issues/40
|
# see https://github.com/facebookresearch/nougat/issues/40
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get install --no-install-recommends -y ffmpeg libsm6 libxext6 && \
|
apt-get install --no-install-recommends -y ffmpeg libsm6 libxext6 && \
|
||||||
pip install uv && uv --version && \
|
pip install uv && uv --version && \
|
||||||
apt-get purge -y --auto-remove tzdata && \
|
apt-get purge -y && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
RUN uv pip install --overrides=numpy-override.txt "comfyui[attention,comfyui_manager]@git+https://github.com/hiddenswitch/ComfyUI.git"
|
RUN uv pip install --overrides=numpy-override.txt "comfyui[attention,comfyui_manager]@git+https://github.com/hiddenswitch/ComfyUI.git"
|
||||||
|
|
||||||
WORKDIR /workspace
|
WORKDIR /workspace
|
||||||
|
# addresses https://github.com/pytorch/pytorch/issues/104801
|
||||||
|
# and issues reported by importing nodes_canny
|
||||||
RUN comfyui --quick-test-for-ci --cpu --cwd /workspace
|
RUN comfyui --quick-test-for-ci --cpu --cwd /workspace
|
||||||
|
|
||||||
EXPOSE 8188
|
EXPOSE 8188
|
||||||
|
|||||||
@ -63,8 +63,8 @@ dependencies = [
|
|||||||
"natsort",
|
"natsort",
|
||||||
"OpenEXR",
|
"OpenEXR",
|
||||||
"opentelemetry-distro",
|
"opentelemetry-distro",
|
||||||
"opentelemetry-sdk<1.35.0",
|
"opentelemetry-sdk",
|
||||||
"opentelemetry-exporter-otlp<=1.27.0",
|
"opentelemetry-exporter-otlp",
|
||||||
"opentelemetry-propagator-jaeger",
|
"opentelemetry-propagator-jaeger",
|
||||||
"opentelemetry-instrumentation",
|
"opentelemetry-instrumentation",
|
||||||
"opentelemetry-util-http",
|
"opentelemetry-util-http",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user