Use tempio to generate RAUC configuration files (#1797)
* Add tempio host package tempio is a template helper using Go's template engine and sprig functions. * Use tempio to generate rauc manifest * Use tempio to generate rauc system.conf
This commit is contained in:
26
buildroot-external/ota/manifest.raucm.gtpl
Normal file
26
buildroot-external/ota/manifest.raucm.gtpl
Normal file
@@ -0,0 +1,26 @@
|
||||
[update]
|
||||
compatible={{ env "ota_compatible" }}
|
||||
version={{ env "ota_version" }}
|
||||
|
||||
[hooks]
|
||||
filename=hook
|
||||
hooks=install-check;
|
||||
|
||||
[image.boot]
|
||||
filename=boot.vfat
|
||||
hooks=install;
|
||||
|
||||
[image.kernel]
|
||||
filename=kernel.img
|
||||
{{- if eq (env "BOOTLOADER") "grub" }}
|
||||
hooks=post-install;
|
||||
{{- end }}
|
||||
|
||||
[image.rootfs]
|
||||
filename=rootfs.img
|
||||
|
||||
{{- if eq (env "BOOT_SPL") "true" }}
|
||||
[image.spl]
|
||||
filename=spl.img
|
||||
hooks=install
|
||||
{{- end }}
|
||||
45
buildroot-external/ota/system.conf.gtpl
Normal file
45
buildroot-external/ota/system.conf.gtpl
Normal file
@@ -0,0 +1,45 @@
|
||||
[system]
|
||||
compatible={{ env "ota_compatible" }}
|
||||
mountprefix=/run/rauc
|
||||
statusfile=/mnt/data/rauc.db
|
||||
bootloader={{ env "BOOTLOADER" }}
|
||||
{{- if eq (env "BOOTLOADER") "grub" }}
|
||||
{{- if eq (env "BOOT_SYS") "efi" }}
|
||||
grubenv=/mnt/boot/EFI/BOOT/grubenv
|
||||
{{- else }}
|
||||
grubenv=/mnt/boot/grubenv
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
[keyring]
|
||||
path=/etc/rauc/keyring.pem
|
||||
|
||||
[slot.boot.0]
|
||||
device=/dev/disk/by-partlabel/hassos-boot
|
||||
type=vfat
|
||||
allow-mounted=true
|
||||
{{- if eq (env "BOOT_SPL") "true" }}
|
||||
[slot.spl.0]
|
||||
device=/dev/disk/by-partlabel/hassos-boot
|
||||
type=raw
|
||||
{{- end }}
|
||||
|
||||
[slot.kernel.0]
|
||||
device=/dev/disk/by-partlabel/hassos-kernel0
|
||||
type=raw
|
||||
bootname=A
|
||||
|
||||
[slot.rootfs.0]
|
||||
device=/dev/disk/by-partlabel/hassos-system0
|
||||
type=raw
|
||||
parent=kernel.0
|
||||
|
||||
[slot.kernel.1]
|
||||
device=/dev/disk/by-partlabel/hassos-kernel1
|
||||
type=raw
|
||||
bootname=B
|
||||
|
||||
[slot.rootfs.1]
|
||||
device=/dev/disk/by-partlabel/hassos-system1
|
||||
type=raw
|
||||
parent=kernel.1
|
||||
Reference in New Issue
Block a user