I’m considering Mender for a project where we need the updates to be user initiated. I.e. something like the behavior of a smartphone or other system with a UI. What we need to achieve is something like this:
User clicks a “Check for Updates” button in the UI (a website served by a local webserver running on the device). Info is displayed about the update/if it is available.
User clicks start update. Update progress is displayed.
1 is optional it’s fine if the user just clicks update and then it updates if an update is available.
It’s also important that the user can update whenever they want. These devices are seldom connected to the internet and the user needs to be able to update even if the update was released 1 month ago.
I think you could set mender-client service to disabled, so that it doesn’t start manually, and then enable it whenever you want to update. Haven’t done it myself, but I would look in that direction.
Expanding a bit on this: Use a Sync state script to check some condition. Usually it returns 1 to signal “do not proceed with update”. If the user clicks the button to update, change the condition and call mender check-update to trigger another execution of the script. When it returns 0, the update can continue.