diff options
author | Anton Gerasimov <anton.gerasimov@here.com> | 2018-09-04 16:56:01 +0200 |
---|---|---|
committer | Anton Gerasimov <anton.gerasimov@here.com> | 2018-10-09 16:11:04 +0200 |
commit | e2c03bd809ddefa9d164b5ba20f8d01957ce2f86 (patch) | |
tree | 5af6ddefbc57728185cd1a11226eb446262f80fb /classes/image_types_ostree.bbclass | |
parent | 42972f0db05b4057a8c552cc10abfc8a634338be (diff) | |
download | meta-updater-e2c03bd809ddefa9d164b5ba20f8d01957ce2f86.tar.gz |
Provide example for setting UPTANE target version automatically
Diffstat (limited to 'classes/image_types_ostree.bbclass')
-rw-r--r-- | classes/image_types_ostree.bbclass | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index 95d1b59..1d43324 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -184,7 +184,7 @@ IMAGE_CMD_ostreepush () { | |||
184 | } | 184 | } |
185 | 185 | ||
186 | IMAGE_TYPEDEP_garagesign = "ostreepush" | 186 | IMAGE_TYPEDEP_garagesign = "ostreepush" |
187 | do_image_garage_sign[depends] += "aktualizr-native:do_populate_sysroot" | 187 | do_image_garagesign[depends] += "aktualizr-native:do_populate_sysroot" |
188 | IMAGE_CMD_garagesign () { | 188 | IMAGE_CMD_garagesign () { |
189 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then | 189 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then |
190 | # if credentials are issued by a server that doesn't support offline signing, exit silently | 190 | # if credentials are issued by a server that doesn't support offline signing, exit silently |
@@ -210,6 +210,8 @@ IMAGE_CMD_garagesign () { | |||
210 | target_version=${ostree_target_hash} | 210 | target_version=${ostree_target_hash} |
211 | if [ -n "${GARAGE_TARGET_VERSION}" ]; then | 211 | if [ -n "${GARAGE_TARGET_VERSION}" ]; then |
212 | target_version=${GARAGE_TARGET_VERSION} | 212 | target_version=${GARAGE_TARGET_VERSION} |
213 | elif [ -e "${STAGING_DATADIR_NATIVE}/target_version" ]; then | ||
214 | target_version=$(cat "${STAGING_DATADIR_NATIVE}/target_version") | ||
213 | fi | 215 | fi |
214 | 216 | ||
215 | # Push may fail due to race condition when multiple build machines try to push simultaneously | 217 | # Push may fail due to race condition when multiple build machines try to push simultaneously |