forked from fedora-iot/greenboot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: Systemd unit file and packaging
Added spec file for packaging greenboot and healthcheck greenboot-healthcheck.service runs the health-check scripts which runs on every boot and is orchestrated before systemd-update-done.services greenboot-rollback.service binds to the systemd-update-done.services to ensure that rollback only runs when a system is updated. Signed-off-by: Sayan Paul <saypaul@redhat.com>
- Loading branch information
Showing
5 changed files
with
134 additions
and
100 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[Unit] | ||
Description=greenboot Health Checks Runner | ||
DefaultDependencies=no | ||
Before=boot-complete.target systemd-update-done.service | ||
OnFailureJobMode=fail | ||
RequiresMountsFor=/boot | ||
RequiresMountsFor=/etc | ||
|
||
[Service] | ||
Type=oneshot | ||
RemainAfterExit=yes | ||
ExecStart=/usr/libexec/greenboot/greenboot health-check | ||
Restart=no | ||
|
||
[Install] | ||
RequiredBy=boot-complete.target | ||
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
|
||
[Unit] | ||
Description=Greenboot rollback | ||
Requires=dbus.service | ||
RequiresMountsFor=/boot | ||
After=systemd-update-done.service | ||
BindsTo=systemd-update-done.service | ||
|
||
[Service] | ||
Type=oneshot | ||
RemainAfterExit=true | ||
ExecStart=/usr/libexec/greenboot/greenboot rollback | ||
Restart=no | ||
|
||
[Install] | ||
WantedBy=multi-user.target |