Skip to content

Commit

Permalink
Fix VarLink Machine.Register invocation
Browse files Browse the repository at this point in the history
  • Loading branch information
labichn committed Jan 23, 2025
1 parent d1f4e67 commit ebbb3ce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mkosi/qemu.py
Original file line number Diff line number Diff line change
Expand Up @@ -999,7 +999,7 @@ def machine1_is_available(config: Config) -> bool:
).stdout.strip()
)

return any(service.name == "org.freedesktop.machine1" for service in services)
return any(service.get("name") == "org.freedesktop.machine1" for service in services)


def finalize_register(config: Config) -> bool:
Expand Down Expand Up @@ -1039,7 +1039,7 @@ def register_machine(config: Config, pid: int, fname: Path, cid: Optional[int])
"name": config.machine_or_name().replace("_", "-"),
"service": "mkosi",
"class": "vm",
"leader": pid,
"leader": {"pid": pid},
**({"rootDirectory": os.fspath(fname)} if fname.is_dir() else {}),
**({"vSockCid": cid} if cid is not None else {}),
**({"sshAddress": f"vsock/{cid}"} if cid is not None else {}),
Expand Down

0 comments on commit ebbb3ce

Please sign in to comment.