mirror of
https://github.com/home-assistant/operating-system.git
synced 2025-07-26 22:46:32 +00:00
Remove existing rauc.db from a data disk on the first boot (#3737)
If data disk is adopted on Yellow using the mechanism added in #3686, it contains RAUC version information that is very likely invalid. In such case, remove the file on first boot and have it recreated by the raucdb-update service.
This commit is contained in:
parent
3b0b0312f6
commit
c7a9a0b906
@ -0,0 +1,14 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Remove adopted rauc.db on first boot
|
||||||
|
After=rauc.service
|
||||||
|
Before=raucdb-update.service
|
||||||
|
RequiresMountsFor=/mnt/data
|
||||||
|
ConditionFirstBoot=yes
|
||||||
|
ConditionFileNotEmpty=/mnt/data/rauc.db
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=oneshot
|
||||||
|
ExecStart=/bin/rm -f /mnt/data/rauc.db
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
Loading…
x
Reference in New Issue
Block a user