Enhance installation state management and diagnostics for ComfyUI

- Updated the `gpu-rent` logic to ensure the `IsInstalled` flag is accurately set based on the presence of ComfyUI, preventing conflicts during installation.
- Improved the handling of the `/mnt/swarm_data` directory to skip creation if it does not exist, enhancing robustness in provisioning.
- Added tests to validate the new installation state checks and ensure proper diagnostics during the installation process, including scenarios for clearing and setting the `IsInstalled` flag.
This commit is contained in:
Leonid Pershin
2026-08-21 12:48:44 +03:00
parent f8ce9d1981
commit 1d18ece17b
4 changed files with 72 additions and 1 deletions
+3
View File
@@ -490,6 +490,9 @@ for p in uniq:
continue
if "/mnt/swarm_data/" not in str(p):
continue
if not Path("/mnt/swarm_data").is_dir():
print(f"skip create {p}: /mnt/swarm_data нет")
continue
p.parent.mkdir(parents=True, exist_ok=True)
p.write_text(
"IsInstalled: true\n"