mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-04-15 13:02:35 +08:00
feat(build,docker): bake SageAttention 2.2 from source and enable in ComfyUI with --use-sage-attention
Adds a multi-stage Docker build that compiles SageAttention 2.2/2++ from the upstream repository head into a wheel using nvcc, then installs it into the slim runtime to keep images small. Ensures the builder installs the same Torch CUDA 12.9 stack as the runtime so the compiled extension ABI matches at load time. Shallow clones the SageAttention repo during build to always pull the latest version on each new image build. Updates the container launch to pass --use-sage-attention so ComfyUI enables SageAttention at startup when the package is present. This change keeps the runtime minimal while delivering up-to-date, high-performance attention kernels for modern NVIDIA GPUs in ComfyUI.
This commit is contained in:
parent
fb64caf236
commit
051c46b6dc
@ -50,4 +50,4 @@ EXPOSE 8188
|
||||
# Start as root so entrypoint can adjust ownership and drop privileges
|
||||
USER root
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
CMD ["python", "main.py", "--listen", "0.0.0.0"]
|
||||
CMD ["python", "main.py", "--listen", "0.0.0.0", "--use-sage-attention"]
|
||||
|
||||
Loading…
Reference in New Issue
Block a user