I’m using hosted mender and my software updates are using the directory module. My application is a system service running python scripts running on a headless RPi. The application is responsible for enabling and connecting a cellular modem and then powering down the device (sudo shutdown) to save power. In the field this process could take 20 seconds once the cellular modem connects i.e. from starting to transfer data to shutting down the connection. I would like to keep track of the mender-client state so my main application can:
- I leave the cell modem on long enough for mender-client to check the server
- After the update has been successfully applied the application can perform a graceful shutdown
I am aware of this thread and it seems that best practice is to use state scripts to pipe states to a file. Since the discussion was about standalone mender I just wanted to ask if there was anything built into the mender-client running in hosted mode i.e. Dbus, etc.
If I was to use state scripts to pipe mender-client status to a file is there any status that are passed to the scripts when they are called i.e. some values representing Idle, Artificat Commit, etc.