Follow-up to Improve the Linux Restore workflow for headless servers by @Chad_Neeper. I’d like to implement the first part of that request and want to check the design first.
Current behaviour: the Restore button only appears if ServerStatus::canRestore() is true, meaning the client is online, its RESTORE mode isn’t disabled, and (with file access tokens) allow_file_restore is on. If any of those fail, the button simply isn’t there. Linux clients ship with RESTORE=disabled in /etc/default/urbackupclient, so on a headless box the first experience is a missing button and no hint why.
Proposal (no change to the security model):
- Have the server tell the web UI why restore is unavailable. It already knows, because the client reports its mode during capability exchange. So return a reason alongside
can_restore: client offline / restores disabled on the client / file restore disabled in server settings. - The UI then shows a disabled Restore button with a short explanation, e.g. “Restores are disabled on this client. Set RESTORE=server-confirms in /etc/default/urbackupclient (Linux) to allow restores started from the server.”
- Optionally, a separate and smaller follow-up: have the Linux installer ask whether to enable
server-confirms, defaulting to the currentdisabled.
The server still can’t change the client’s restore mode, so it stays the client’s decision, as Chad asked.
@uroni: is that acceptable, and do you prefer the wording or the installer prompt handled differently? I’d start with 1 and 2.