Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failing on copying .git directories on image build #2054

Open
alexeevit opened this issue Nov 13, 2024 · 0 comments
Open

Failing on copying .git directories on image build #2054

alexeevit opened this issue Nov 13, 2024 · 0 comments

Comments

@alexeevit
Copy link

alexeevit commented Nov 13, 2024

Hi, I've got an ComfyUI project (based on fofr/cog-comfyui) with custom_nodes being git submodules.
When I'm trying to build the image and push it with separate-weights, it fails.

Here's the full log:

$ cog push --separate-weights r8.im/username/model
Building Docker image from environment in cog.yaml as r8.im/username/model...
⚠ Stripping patch version from Python version 3.10.6 to 3.10
⚠ Stripping patch version from Python version 3.10.6 to 3.10
[+] Building 1.3s (9/9) FINISHED                                                                                                             docker:orbstack
 => [internal] load build definition from Dockerfile                                                                                                    0.0s
 => => transferring dockerfile: 378B                                                                                                                    0.0s
 => resolve image config for docker-image://docker.io/docker/dockerfile:1.4                                                                             0.8s
 => [auth] docker/dockerfile:pull token for registry-1.docker.io                                                                                        0.0s
 => CACHED docker-image://docker.io/docker/dockerfile:1.4@sha256:9ba7531bd80fb0a858632727cf7a112fbfd19b17e94c4e84ced81e24ef1a0dbc                       0.0s
 => [internal] load .dockerignore                                                                                                                       0.0s
 => => transferring context: 1.32kB                                                                                                                     0.0s
 => [internal] load build context                                                                                                                       0.0s
 => => transferring context: 8.94kB                                                                                                                     0.0s
 => CACHED [1/3] COPY checkpoints /src/checkpoints                                                                                                      0.0s
 => ERROR [2/3] COPY ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack /src/ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack         0.0s
 => ERROR [3/3] COPY ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack /src/ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack   0.0s
------
 > [2/3] COPY ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack /src/ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack:
------
------
 > [3/3] COPY ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack /src/ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack:
------
Dockerfile:6
--------------------
   4 |     COPY checkpoints /src/checkpoints
   5 |     COPY ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack /src/ComfyUI/custom_nodes/ComfyUI-Impact-Pack/.git/objects/pack
   6 | >>> COPY ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack /src/ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack
--------------------
ERROR: failed to solve: failed to compute cache key: failed to calculate checksum of ref 6a73706f-b490-4655-9039-d425601e8e52::si305044bnfz83rhiruyd9q4b: "/ComfyUI/custom_nodes/comfyui_controlnet_aux/.git/objects/pack": not found

TBH I don't even care about it not being able to find the directory, it worries me that it shouldn't copy the .git directories at all, taking into account that both **/.git and .git present in .dockerignore.

$ cog --version
cog version 0.13.0 (built 2024-11-05T18:15:42Z)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant