feat: added comfy ui

This commit is contained in:
Nick 2025-07-18 17:21:16 -05:00
parent 9598576855
commit b94b8b2ba4

View file

@ -9,17 +9,22 @@ let
cfg = config.services.comfyui; cfg = config.services.comfyui;
in in
{ {
options.services.comfyui = with lib; { imports = [ ];
options = {
services.comfyui = with lib; {
enable = mkEnableOption "ComfyUI service"; enable = mkEnableOption "ComfyUI service";
package = mkOption { package = mkOption {
type = types.package; type = types.package;
default = pkgs.comfyuiPackages.comfyui.override { default = pkgs.comfyuiPackages.comfyui.override {
extensions = with pkgs.comfyuiPackages.extensions; [ extensions = with pkgs.comfyuiPackages.extensions; [
acly-inpaint # Add desired extensions here
acly-tooling # Example extensions:
cubiq-ipadapter-plus # acly-inpaint
fannovel16-controlnet-aux # acly-tooling
# cubiq-ipadapter-plus
# fannovel16-controlnet-aux
]; ];
commandLineArgs = [ commandLineArgs = [
"--preview-method" "--preview-method"
@ -37,7 +42,7 @@ in
host = mkOption { host = mkOption {
type = types.str; type = types.str;
default = "0.0.0.0"; default = "127.0.0.1";
description = "Host to bind to"; description = "Host to bind to";
}; };
@ -47,6 +52,7 @@ in
description = "Open ports in the firewall"; description = "Open ports in the firewall";
}; };
}; };
};
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
environment.systemPackages = [ cfg.package ]; environment.systemPackages = [ cfg.package ];
@ -79,19 +85,4 @@ in
users.groups.comfyui = { }; users.groups.comfyui = { };
}; };
services.comfyui = {
enable = true;
package = pkgs.comfyuiPackages.comfyui.override {
extensions = with pkgs.comfyuiPackages.extensions; [
acly-inpaint
acly-tooling
cubiq-ipadapter-plus
fannovel16-controlnet-aux
];
commandLineArgs = [
"--preview-method"
"auto"
];
};
};
} }