mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-06-04 05:17:50 +08:00
feat: expose comfy-api/platform base URLs via /features
Adds --comfy-platform-base CLI flag mirroring --comfy-api-base, and surfaces both through the existing /features endpoint as comfy_api_base_url and comfy_platform_base_url. Lets the frontend discover at runtime which backend the local server expects it to talk to, so an ephemeral or self-hosted comfy-api deployment can be wired up without rebuilding the frontend bundle. Companion frontend change consumes these keys.
This commit is contained in:
parent
cd45f42a83
commit
fd41506b75
@ -231,6 +231,13 @@ parser.add_argument(
|
||||
help="Set the base URL for the ComfyUI API. (default: https://api.comfy.org)",
|
||||
)
|
||||
|
||||
parser.add_argument(
|
||||
"--comfy-platform-base",
|
||||
type=str,
|
||||
default="https://platform.comfy.org",
|
||||
help="Set the base URL for the ComfyUI Platform. (default: https://platform.comfy.org)",
|
||||
)
|
||||
|
||||
database_default_path = os.path.abspath(
|
||||
os.path.join(os.path.dirname(__file__), "..", "user", "comfyui.db")
|
||||
)
|
||||
|
||||
@ -99,6 +99,8 @@ _CORE_FEATURE_FLAGS: dict[str, Any] = {
|
||||
"extension": {"manager": {"supports_v4": True}},
|
||||
"node_replacements": True,
|
||||
"assets": args.enable_assets,
|
||||
"comfy_api_base_url": args.comfy_api_base,
|
||||
"comfy_platform_base_url": args.comfy_platform_base,
|
||||
}
|
||||
|
||||
# CLI-provided flags cannot overwrite core flags
|
||||
|
||||
Loading…
Reference in New Issue
Block a user