Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion services/comfy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ FROM pytorch/pytorch:2.5.1-cuda12.4-cudnn9-runtime

ENV DEBIAN_FRONTEND=noninteractive PIP_PREFER_BINARY=1

RUN apt-get update && apt-get install -y git libgoogle-perftools-dev && apt-get clean
# libgl1 and libglib2.0-0 are required for opencv-python
RUN apt-get update && apt-get install -y git libgoogle-perftools-dev libgl1 libglib2.0-0 && apt-get clean

ARG PUID=0
ARG PGID=0
Expand Down
22 changes: 22 additions & 0 deletions services/comfy/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,28 @@ for to_path in "${!MOUNTS[@]}"; do
echo "Mounted ${from_path} -> ${to_path}"
done

if [ -d "${ROOT}/comfyui-manager" ]; then
manager_exists=false
shopt -s nullglob
for dir in "${ROOT}/custom_nodes"/*; do
dirname=$(basename "$dir")
if [[ "${dirname,,}" == "comfyui-manager" ]]; then
manager_exists=true
break
fi
done
shopt -u nullglob

if [ "$manager_exists" = false ]; then
echo "Initializing ComfyUI-Manager..."
# Debug: List contents to see why it wasn't found (optional, can be removed later)
ls -la "${ROOT}/custom_nodes" || true
cp -r "${ROOT}/comfyui-manager" "${ROOT}/custom_nodes/comfyui-manager"
else
echo "ComfyUI-Manager detected in custom_nodes, skipping initialization."
fi
fi

if [ -f "/data/config/comfy/startup.sh" ]; then
pushd ${ROOT}
. /data/config/comfy/startup.sh
Expand Down