summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Agner <stefan.agner@toradex.com>2020-06-15 08:27:36 +0000
committerMing Liu <ming.liu@toradex.com>2020-06-27 10:38:10 +0200
commit6a0fa6a8a4e66fb1502e2ff2e1b708eb45d4e179 (patch)
tree110a7f480ecc8a33bbc5b284e95d9f3972c09739
parent75069b6a653a19e298c1b2ea791e80955a26b7b6 (diff)
downloadmeta-updater-6a0fa6a8a4e66fb1502e2ff2e1b708eb45d4e179.tar.gz
aktualizr: make use of boot-complete.target
From the systemd.special(7) man page section boot-complete.target: This target is intended as generic synchronization point for services that shall determine or act on whether the boot process completed successfully. Let's make use of the target. Since aktualizr by default marks a boot as successful, we consider aktualizr.service a service which needs to be executed on successful boot (hence after the boot-complete.target). This allows to declare a service as crucial by simply ordering it before the boot-complete.target. The systemd example service systemd-boot-check-no-failures.service can serve as an example. This change does not add any service dependency by default as boot-complete.target by default does not has any extra dependencies. Note that rebooting in the failure case is not handled by this mechanism. This can be added by using FailureAction. Boot assessement infrastructure got introduced with systemd 240. See also: https://systemd.io/AUTOMATIC_BOOT_ASSESSMENT/ Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
-rw-r--r--recipes-sota/aktualizr/files/aktualizr.service3
1 files changed, 2 insertions, 1 deletions
diff --git a/recipes-sota/aktualizr/files/aktualizr.service b/recipes-sota/aktualizr/files/aktualizr.service
index 3d807a1..ae5d23a 100644
--- a/recipes-sota/aktualizr/files/aktualizr.service
+++ b/recipes-sota/aktualizr/files/aktualizr.service
@@ -1,6 +1,7 @@
1[Unit] 1[Unit]
2Description=Aktualizr SOTA Client 2Description=Aktualizr SOTA Client
3After=network-online.target nss-lookup.target 3After=network-online.target nss-lookup.target boot-complete.target
4Requires=boot-complete.target
4Wants=network-online.target 5Wants=network-online.target
5 6
6[Service] 7[Service]