diff options
Diffstat (limited to 'classes')
| -rw-r--r-- | classes/image_types_ostree.bbclass | 8 | ||||
| -rw-r--r-- | classes/sota.bbclass | 5 |
2 files changed, 10 insertions, 3 deletions
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index b1c53ff..a9a8174 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
| @@ -7,6 +7,8 @@ OSTREE_COMMIT_SUBJECT ??= "Commit-id: ${IMAGE_NAME}" | |||
| 7 | OSTREE_COMMIT_BODY ??= "" | 7 | OSTREE_COMMIT_BODY ??= "" |
| 8 | OSTREE_UPDATE_SUMMARY ??= "0" | 8 | OSTREE_UPDATE_SUMMARY ??= "0" |
| 9 | OSTREE_DEPLOY_DEVICETREE ??= "0" | 9 | OSTREE_DEPLOY_DEVICETREE ??= "0" |
| 10 | OSTREE_BRANCHNAME ?= "${SOTA_HARDWARE_ID}" | ||
| 11 | GARAGE_TARGET_NAME ?= "${OSTREE_BRANCHNAME}" | ||
| 10 | 12 | ||
| 11 | BUILD_OSTREE_TARBALL ??= "1" | 13 | BUILD_OSTREE_TARBALL ??= "1" |
| 12 | 14 | ||
| @@ -254,6 +256,12 @@ IMAGE_CMD_garagesign () { | |||
| 254 | ${target_url} \ | 256 | ${target_url} \ |
| 255 | --sha256 ${ostree_target_hash} \ | 257 | --sha256 ${ostree_target_hash} \ |
| 256 | --hardwareids ${SOTA_HARDWARE_ID} | 258 | --hardwareids ${SOTA_HARDWARE_ID} |
| 259 | if [ -n "${GARAGE_CUSTOMIZE_TARGET}" ]; then | ||
| 260 | bbplain "Running command(${GARAGE_CUSTOMIZE_TARGET}) to customize target" | ||
| 261 | ${GARAGE_CUSTOMIZE_TARGET} \ | ||
| 262 | ${GARAGE_SIGN_REPO}/tufrepo/roles/unsigned/targets.json \ | ||
| 263 | ${GARAGE_TARGET_NAME}-${target_version} | ||
| 264 | fi | ||
| 257 | garage-sign targets sign --repo tufrepo \ | 265 | garage-sign targets sign --repo tufrepo \ |
| 258 | --home-dir ${GARAGE_SIGN_REPO} \ | 266 | --home-dir ${GARAGE_SIGN_REPO} \ |
| 259 | --key-name=targets | 267 | --key-name=targets |
diff --git a/classes/sota.bbclass b/classes/sota.bbclass index bf27b6d..1a9d68b 100644 --- a/classes/sota.bbclass +++ b/classes/sota.bbclass | |||
| @@ -39,7 +39,6 @@ INITRAMFS_FSTYPES ?= "${@oe.utils.ifelse(d.getVar('OSTREE_BOOTLOADER') == 'u-boo | |||
| 39 | 39 | ||
| 40 | # Please redefine OSTREE_REPO in order to have a persistent OSTree repo | 40 | # Please redefine OSTREE_REPO in order to have a persistent OSTree repo |
| 41 | export OSTREE_REPO ?= "${DEPLOY_DIR_IMAGE}/ostree_repo" | 41 | export OSTREE_REPO ?= "${DEPLOY_DIR_IMAGE}/ostree_repo" |
| 42 | export OSTREE_BRANCHNAME ?= "${SOTA_HARDWARE_ID}" | ||
| 43 | export OSTREE_OSNAME ?= "poky" | 42 | export OSTREE_OSNAME ?= "poky" |
| 44 | export OSTREE_BOOTLOADER ??= 'u-boot' | 43 | export OSTREE_BOOTLOADER ??= 'u-boot' |
| 45 | export OSTREE_BOOT_PARTITION ??= "/boot" | 44 | export OSTREE_BOOT_PARTITION ??= "/boot" |
| @@ -48,9 +47,9 @@ INITRAMFS_IMAGE ?= "initramfs-ostree-image" | |||
| 48 | 47 | ||
| 49 | GARAGE_SIGN_REPO ?= "${DEPLOY_DIR_IMAGE}/garage_sign_repo" | 48 | GARAGE_SIGN_REPO ?= "${DEPLOY_DIR_IMAGE}/garage_sign_repo" |
| 50 | GARAGE_SIGN_KEYNAME ?= "garage-key" | 49 | GARAGE_SIGN_KEYNAME ?= "garage-key" |
| 51 | GARAGE_TARGET_NAME ?= "${OSTREE_BRANCHNAME}" | ||
| 52 | GARAGE_TARGET_VERSION ?= "" | 50 | GARAGE_TARGET_VERSION ?= "" |
| 53 | GARAGE_TARGET_URL ?= "" | 51 | GARAGE_TARGET_URL ?= "" |
| 52 | GARAGE_CUSTOMIZE_TARGET ?= "" | ||
| 54 | 53 | ||
| 55 | SOTA_MACHINE ??="none" | 54 | SOTA_MACHINE ??="none" |
| 56 | SOTA_MACHINE_rpi ?= "raspberrypi" | 55 | SOTA_MACHINE_rpi ?= "raspberrypi" |
| @@ -61,6 +60,6 @@ SOTA_MACHINE_qemux86-64 ?= "qemux86-64" | |||
| 61 | SOTA_MACHINE_am335x-evm ?= "am335x-evm-wifi" | 60 | SOTA_MACHINE_am335x-evm ?= "am335x-evm-wifi" |
| 62 | 61 | ||
| 63 | SOTA_OVERRIDES_BLACKLIST = "ostree ota" | 62 | SOTA_OVERRIDES_BLACKLIST = "ostree ota" |
| 64 | SOTA_REQUIRED_VARIABLES = "OSTREE_REPO OSTREE_BRANCHNAME OSTREE_OSNAME OSTREE_BOOTLOADER OSTREE_BOOT_PARTITION GARAGE_SIGN_REPO GARAGE_TARGET_NAME" | 63 | SOTA_REQUIRED_VARIABLES = "OSTREE_REPO OSTREE_OSNAME OSTREE_BOOTLOADER OSTREE_BOOT_PARTITION GARAGE_SIGN_REPO" |
| 65 | 64 | ||
| 66 | inherit sota_sanity sota_${SOTA_MACHINE} image_repo_manifest | 65 | inherit sota_sanity sota_${SOTA_MACHINE} image_repo_manifest |
