Good time of the day.
I have been working on Mender integration within the system I have on my end and came to a bit of a roadblock with
mender-configure addon to be quite useful for setting per-device timezones and hostnames (possibly, more things will be set later). Hence, I would like to keep the addon. However, it does seem to have some limitations. Let me elaborate.
Current system design:
dirupdate module is being used to release application-level updates.
rootfsupdate module is being used to release system-level updates.
mender-configureaddon is being used to set hostname and timezones per-device.
Note: App is packed inside
rootfs updates whenever a
rootfs update is released.
Current boot up flow:
- RPi boots up
- Custom application boots up and goes into idle mode for 3 minutes. This allows mender-client to check for an update
- In case update is available,
Download_Enterrootfs state script sends a command to an application to be terminated. In case no update is available, application times out within 3 minutes and starts executing regular flow.
Because of aforementioned app termination in case of update availability, an application boot up must happen some time:
- In terms of
rootfsupdates, system reboot will happen anyway to switch between A/B partitions. This will be sufficient to kickstart the bootup of a new app. (keeping in mind that new app is packed within
- In case of
dirupdate, no system reboot will happen but
ArtifactFailure_Leavestate scripts will handle an application bootup.
- In case of
mender-configureupdate, there is no clear way of kickstarting an application.
So far, I think these are some possibilities:
- Improve logic of
Download_Enterstate script by checking what type of deployment is pending. But for this, an ability to read deployment info is required. Is it possible to read deployment info from
- Attach a state script to
mender-configuregenerated artifacts (to make it look similar to
dir). However this note makes me thing this might be impossible. Is it possible to interact with the way
mender-configuregenerates the artifacts on the backend?
ArtifactFailure_Leavestate scripts away from the artifacts and put them under
rootfs. Will they even be run in such a case?
I am looking forward to any ideas at this stage.