main
John Lauer Publish 0.1.0 d8a45ab

name: hydrogen-runtime-mode description: >- Which runtime hosts your Hydrogen workspace on Linux: always the Adom-Workspace systemd-nspawn machine (NspawnHost), how to tell, and what that means for files, ports and exec. Use when asked am I in docker, a VM or a container, which runtime, or when workspace networking, ports or setup advice conflicts.

Hydrogen Runtime Mode on Linux: systemd-nspawn, always

On a Linux desktop Hydrogen has exactly one workspace runtime: NspawnHost, the Adom-Workspace systemd-nspawn machine on the host kernel (select_runtime() in hydrogen-runtime/src/runtime/mod.rs returns it unconditionally on Linux; the host prep is runtime/linux.rs). There is no Docker runtime, no VM, and no switch. If any advice assumes a different runtime, it is the wrong advice for this machine.

Which runtime am I in? (authoritative checks)

  1. From inside the workspace: systemd-detect-virt prints systemd-nspawn; /mnt/host/home exists.
  2. Hydrogen's API: curl -s "$(cat ~/.adom/hydrogen-control-url)/container-stats" shows "runtime": "nspawn_host" and "image": "systemd-nspawn: Adom-Workspace".
  3. Hydrogen's log (~/.config/hydrogen-desktop/ on the host): [app] Active workspace runtime: NspawnHost.
  4. On the host: machinectl list shows Adom-Workspace.

What this runtime means

Concern systemd-nspawn on Linux
Workspace Adom-Workspace, the golden rootfs unpacked into /var/lib/machines/Adom-Workspace
Kernel the host's own (no VM); /proc/meminfo inside is the whole PC's
Run a command in it (host side) Hydrogen's root helper: sudo -n /usr/libexec/adom-hydrogen/hydrogen-workspace -d Adom-Workspace -u adom -- <cmd> (it enters the machine with nsenter)
Your files /home/adom/project in the machine's rootfs on the host disk; host /home is mounted at /mnt/host/home
Ports shared host network namespace: 127.0.0.1 is the same inside and outside; workspace ports are dropped for inbound LAN traffic by the helper's adom_hydrogen nft table
Reach Hydrogen 127.0.0.1; the live control URL is in ~/.adom/hydrogen-control-url
Wipe/reset Virgin Reset in the Setup panel (removes only Adom-Workspace through machinectl)

Some API endpoints and env names keep their historical names (/wsl/status, the helper hydrogen-workspace, WSL_DISTRO_NAME): they serve the nspawn machine here.

Which skills to trust

The workspace skills on this machine (hydrogen-container, hydrogen-networking, hydrogen-ports, hydrogen-volume, hydrogen-topology, hydrogen-setup, hydrogen-setup-steps, hydrogen-workspace-lifecycle, hydrogen-workspace-monitoring, ...) are the Linux versions. If something tells you to use docker exec, named volumes, or a VM's console, it does not apply here.