mirror of
https://github.com/jamesstringer90/appsandbox.git
synced 2026-10-22 11:03:15 -05:00
Add POST/DELETE/GET /vms/{name}/display plus the open_display/close_display/display_status/display_ready SDK methods, so a script can open and close a VM's display window like the GUI's Connect button.
Readiness is a latched flag, not a frame-channel probe: connecting to the guest frame service is itself becoming the display's single consumer, so polling it would steal the slot and blank the display. The guest agent reports the display driver state over the agent channel (idd_status) and the host latches it as idd_ready; asb_vm_idd_ready = running && agent_online && idd_ready. The Linux agent reports idd_status:ok once the user session is up (Mutter compositing).
The display window is daemon-owned (per-VM table keyed by unique_id), gated on a visible window station, and self-tears-down on the X button; displayOpen is read from the live window state, so it is honest however the window closed.
App Sandbox Linux guest daemons
In-VM Linux daemons that speak the same vsock wire protocol the Windows
App Sandbox host expects. See docs/linux-idd-implementation-plan.md in
the repo root for full architecture and wire-protocol reference.
Daemons (this directory)
| Binary | Channel | Listens on | Privilege | Status |
|---|---|---|---|---|
appsandbox-agent |
control | vsock :1 | root (system) | implemented |
appsandbox-input |
input | vsock :3 | root (system) | planned |
appsandbox-display |
frames + cursor | vsock :2 | root (system) | planned |
appsandbox-clipboard |
clipboard | vsock :5, :6 | user (user unit) | planned |
Build (inside the VM)
sudo apt-get install -y build-essential
make
Install + enable (inside the VM)
sudo make enable
This installs to /usr/local/bin/, drops the systemd unit into
/etc/systemd/system/, runs daemon-reload, then
systemctl enable --now appsandbox-agent.service.
Smoke test
systemctl status appsandbox-agent
journalctl -u appsandbox-agent -f
You should see listening on AF_VSOCK port 1. Once the host-side Phase 1
service-GUID switch lands, the App Sandbox UI's agent dot will turn green
within a few seconds of the unit being active.
Uninstall
sudo make disable
sudo rm /usr/local/bin/appsandbox-agent /etc/systemd/system/appsandbox-agent.service
sudo systemctl daemon-reload