ai-dock/comfyui

Building the docker image fails

pedropaf opened this issue · 5 comments

hi, I've cloned your repo, and I'm trying to build the docker image as is. I'm using ubuntu in wsl2, I'm getting this error:

_28.95 Processing triggers for man-db (2.10.2-1) ...
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/ee0ed9e9.json" was modified by another program
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/edb1952f.json" was modified by another program
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/c9ddbd6b.json" was modified by another program
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/b121c3e7.json" was modified by another program
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/497deca9.json" was modified by another program
29.42 warning libmamba Cache file "/opt/micromamba/pkgs/cache/09cdf8bf.json" was modified by another program
46.80 error libmamba Could not solve for environment specs
46.80 The following package could not be installed
46.80 └─ libglib 2.78.4 h4648e47_1 does not exist (perhaps a typo or a missing channel).
46.81 critical libmamba Could not solve for environment specs

Dockerfile:20

18 |
19 | ARG IMAGE_BASE
20 | >>> RUN set -eo pipefail && /opt/ai-dock/bin/build/layer0/init.sh | tee /var/log/build.log
21 |
22 | # Must be set after layer0

ERROR: failed to solve: process "/bin/bash -c set -eo pipefail && /opt/ai-dock/bin/build/layer0/init.sh | tee /var/log/build.log" did not complete successfully: exit code: 1
ERROR: Service 'supervisor' failed to build : Build failed_

the issue happens from /build/COPY_ROOT/opt/ai-dock/bin/build/layer0/common.sh. Specifically on this line: $MAMBA_CREATE -n comfyui --file "${exported_env}", I can see the library and version in the error above that it's present in the list of dependencies exported to create the comfyui env. I'm not that familiar with micromamba. If this is an easy fix it'd be great to get it fixed, thanks.

I'm having a similar issue:

error libmamba Could not solve for environment specs
The following package could not be installed
└─ libglib 2.78.4 h4648e47_1 does not exist (perhaps a typo or a missing channel).
critical libmamba Could not solve for environment specs
The command '/bin/bash -c set -eo pipefail && /opt/ai-dock/bin/build/layer0/init.sh | tee /var/log/build.log' returned a non-zero code: 1
ERROR: Service 'supervisor' failed to build : Build failed

I started seeing this same exact error yesterday, it was building for me the previous day.

The problem is with the underlying PyTorch image causing this image to fail at build time.

I'll rebuild the full stack of lower layers (pytorch, jupyter-pytorch) to fix the issue but it is a problem that may reappear in the future when building with the documented technique because when we build ComfyUI we have to recreate the existing pytorch install 1:1 which won't work if the repos delete files that were previously available.

A workaround when this happens (rare) is to define your own build process that builds upon the pre-built ComfyUI image but you'd need to handle node installation manually.

Expect builds to be working again within the next few hours.

Base image rebuilds are complete and ComfyUI should now build correctly. Let me know if any further issues

Still having the same issue. Maybe my docker-compose file is wrong. I want to virtualize comfyui in a docker in a proxmox vm with the cpu unly build. What I did was set up a new vm, ran updates and upgrades and cloned the repo. Then I changed the image in the docker compose file as follows:

    build:
      context: ./build
      args:
        IMAGE_BASE: ${IMAGE_BASE:-ghcr.io/ai-dock/comfyui:latest-cpu-jupyter}
      #tags:
      #  - "ghcr.io/ai-dock/comfyui:latest-cpu-jupiter"
    image: ghcr.io/ai-dock/comfyui:latest-cpu-jupiter

Is this the right way to do it and if not what did i do wrong and have to do to fix it ?
tags is commented out because docker-compose gave errors if not.