Defter77 commited on
Commit
07ddda7
·
verified ·
1 Parent(s): ee2f3a1

Upload Dockerfile with huggingface_hub

Browse files
Files changed (1) hide show
  1. Dockerfile +66 -0
Dockerfile ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM nvidia/cuda:12.1.0-runtime-ubuntu22.04
2
+
3
+ # Environment variables
4
+ ENV PYTHONUNBUFFERED=1 \
5
+ PYTHONDONTWRITEBYTECODE=1 \
6
+ PIP_NO_CACHE_DIR=1 \
7
+ DEBIAN_FRONTEND=noninteractive
8
+
9
+ # System dependencies
10
+ RUN apt-get update && apt-get install -y \
11
+ python3.10 python3-pip git wget \
12
+ libgl1-mesa-glx libglib2.0-0 libsm6 libxrender1 libxext6 ffmpeg \
13
+ && rm -rf /var/lib/apt/lists/*
14
+
15
+ # Create app directory
16
+ WORKDIR /app
17
+
18
+ # Clone ComfyUI core
19
+ RUN git clone https://github.com/comfyanonymous/ComfyUI.git
20
+
21
+ # Clone custom nodes
22
+ RUN git clone https://github.com/cubiq/ComfyUI_IPAdapter_plus /app/ComfyUI/custom_nodes/IPAdapter_plus && \
23
+ git clone https://github.com/Kosinkadink/ComfyUI-KJNodes /app/ComfyUI/custom_nodes/KJNodes && \
24
+ git clone https://github.com/SSitu/ComfyUI_UltimateSDUpscale /app/ComfyUI/custom_nodes/UltimateSDUpscale && \
25
+ git clone https://github.com/ltdrdata/PuLID_ComfyUI /app/ComfyUI/custom_nodes/PuLID && \
26
+ git clone https://github.com/cg196/ComfyUI-UseEverywhere /app/ComfyUI/custom_nodes/UseEverywhere && \
27
+ git clone https://github.com/melMass/comfy-mtb /app/ComfyUI/custom_nodes/mtb && \
28
+ git clone https://github.com/LucianoCirino/ComfyUI_Masquerade /app/ComfyUI/custom_nodes/Masquerade && \
29
+ git clone https://github.com/Fannovel16/comfyui-save-image-with-geninfo /app/ComfyUI/custom_nodes/SaveGenInfo && \
30
+ git clone https://github.com/jamesWalker55/comfyui-various /app/ComfyUI/custom_nodes/Various
31
+
32
+ # Create necessary directories
33
+ RUN mkdir -p /app/ComfyUI/models/checkpoints \
34
+ /app/ComfyUI/models/controlnet \
35
+ /app/ComfyUI/models/ipadapter \
36
+ /app/ComfyUI/models/pulid \
37
+ /app/ComfyUI/models/clip_vision \
38
+ /app/ComfyUI/input \
39
+ /app/workflows
40
+
41
+ # Copy workflow file
42
+ COPY workflows/Workflow_12_11.json /app/workflows/
43
+
44
+ # Copy default input images
45
+ COPY ComfyUI/input/*.jpg /app/ComfyUI/input/
46
+
47
+ # Install Python dependencies
48
+ COPY requirements.txt .
49
+ RUN pip3 install --no-cache-dir -r requirements.txt
50
+
51
+ # Copy model download script
52
+ COPY download_models.py .
53
+ RUN python3 download_models.py || true
54
+
55
+ # Copy application code
56
+ COPY app.py .
57
+ COPY start.sh .
58
+
59
+ # Make scripts executable
60
+ RUN chmod +x /app/start.sh
61
+
62
+ # Expose ports for Gradio and ComfyUI
63
+ EXPOSE 7860 8188
64
+
65
+ # Set the entrypoint
66
+ ENTRYPOINT ["/app/start.sh"]