Linux and Windows desktop app: connect to an existing Ovis server (client-only), as #3989 asks for macOS
What
The Linux and Windows desktop apps cannot be pointed at an Ovis server that is already running: they always start their own and open a window on it. This is the Linux/Windows counterpart of #3989, which asks for the same thing under a macOS title, so it is findable and testable on these two platforms.
Where it comes from, in the v0.5.4 source
The desktop app is one shared Electron shell for all three platforms (app/electron/src/main.ts, children.ts, renderer/), so this is not a per-platform gap — but the behaviour is the same everywhere:
app/electron/src/main.ts,launch()— alwaysinstallCore→startCore→choosePort→startServer, and thenwindow.loadURL(server.url). There is no branch that opens an address the app did not spawn itself.app/electron/src/children.ts,serverEnv()— forcesHOST: "127.0.0.1"andPORT, and drops inherited settings. No environment variable or setting points the window at another server.renderer/connect.html— the connection screen offers only Try again and Show logs; there is no address field.
My case, which is probably common on Linux
Fedora 44. This machine already runs an Ovis server from the herdr plugin, and that is the server my browser and my phone reach. The desktop app starts a second one with its own HC_SESSION=ovis and its own state folder, so it shows none of what the web and the phone show, and every PC would have to be added again in that duplicate instance. On a PC where Ovis already runs, a client-only mode would also mean the app needs neither its own herdr-core nor its own server process.
This sits next to #4041 (no .rpm, so the AppImage is the only Linux path today): a client-only mode is the case where the AppImage is most useful, since it needs nothing installed beside it.
What it would take
Opening another address is small; the lifecycle around it is the work:
- Tray: Restart Ovis Server and Quit stops the server mean nothing against a server the app did not start.
- The trusted-origin list behind the microphone, clipboard and notification grants ("the server's own pages").
- Keep Computer Awake, which reads
desktop-activity.jsonfrom the local state folder. ovis://opencarryingmachine.- TLS for a remote
httpsaddress.
The phone pairing rules (address, pairing code, fingerprint) look like the model to reuse rather than a new trust path. On the same machine the simplest case is plain http://127.0.0.1:<port>, which needs no pairing at all.
Relationship to #3989
Same underlying change, already open with a macOS title. If you would rather keep one ticket, closing this in favour of #3989 is fine — but then its title should stop naming macOS alone, because Linux and Windows users will not find it and cannot tell whether a fix covers them.
Happy to test a build on Fedora with the herdr plugin's server as the target.
Tested on Ovis 0.5.6 (AppImage) on Fedora 44, against a second Ovis on the same machine (http://127.0.0.1:7317, an instance started by a herdr plugin).
Most of this is now shipped. #4258 gave Add a connection three tabs (Ovis relay, Tailscale, Direct), #4264 added the server side (Machine.kind: "address" saved in <stateDir>/address-pcs.json, POST /api/machines/address) and #4272 the Direct field that asks for the code. Pairing with the six-digit code that PC shows adds it as a machine, and its workspaces, panes and Chat render inside the app, proxied through /api/machines/<id>/…. The practical need is met: the app shows the existing server's view instead of an empty session of its own. Thanks for that.
The client-only half is still missing, and I think it is worth an option rather than closing this. The app always runs its own server and has no way not to: launch() in app/electron/src/main.ts calls startServer(...) unconditionally and then loads server.url; the only other page the window can show is connect.html through loadFile, which offers Try again / Show logs. No flag, env var or desktop.json key turns the embedded server off, so on Linux and Windows the window cannot be a client of a server it did not start — it reaches the other PC through its own server, with its own HC_SESSION=ovis, state dir and port.
An "Open an existing Ovis" mode (no embedded server, the window loads that address instead) would cover it. From reading the code, what makes this more than one loadURL:
ours()(main.ts:78) admits the microphone, clipboard and notifications only for the embedded server's origin, so a remote address gets none of them;- the tray's Restart Ovis Server has no server to act on;
- Keep Computer Awake reads
desktop-activity.jsonfrom the state dir of the server the app runs (awake.ts); ovis://openlinks are handed to "the server's page", and a remotehttpsaddress needs its certificate trusted.
The same applies to #3989 for macOS; the Electron shell is shared, so one change covers all three. Happy to test a branch against a real second instance.