diff options
author | Laurent Bonnans <laurent.bonnans@here.com> | 2019-11-08 13:50:36 +0100 |
---|---|---|
committer | Patrick Vacek <patrickvacek@gmail.com> | 2019-11-20 10:42:33 +0100 |
commit | 838b59f39e72e623fdc0a10bcf9c3524be1f7330 (patch) | |
tree | 5fcd03966a5cbfc16baeef7ece756b621f10a45f | |
parent | 0a79da1dd5bd3672cecd983ec7630958445f5ab8 (diff) | |
download | meta-updater-838b59f39e72e623fdc0a10bcf9c3524be1f7330.tar.gz |
Send a copy of repo manifest through garage-push
Signed-off-by: Laurent Bonnans <laurent.bonnans@here.com>
Signed-off-by: Patrick Vacek <patrickvacek@gmail.com>
-rw-r--r-- | classes/image_types_ostree.bbclass | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index 0e047b1..f10e523 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -186,13 +186,19 @@ IMAGE_CMD_ostreecommit () { | |||
186 | IMAGE_TYPEDEP_ostreepush = "ostreecommit" | 186 | IMAGE_TYPEDEP_ostreepush = "ostreecommit" |
187 | do_image_ostreepush[depends] += "aktualizr-native:do_populate_sysroot ca-certificates-native:do_populate_sysroot" | 187 | do_image_ostreepush[depends] += "aktualizr-native:do_populate_sysroot ca-certificates-native:do_populate_sysroot" |
188 | IMAGE_CMD_ostreepush () { | 188 | IMAGE_CMD_ostreepush () { |
189 | # Print warnings if credetials are not set or if the file has not been found. | 189 | # send a copy of the repo manifest to backend if available |
190 | local SEND_MANIFEST="" | ||
191 | if [ -f ${IMAGE_ROOTFS}${sysconfdir}/manifest.xml ]; then | ||
192 | SEND_MANIFEST="--repo-manifest ${IMAGE_ROOTFS}${sysconfdir}/manifest.xml" | ||
193 | fi | ||
194 | |||
190 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then | 195 | if [ -n "${SOTA_PACKED_CREDENTIALS}" ]; then |
191 | if [ -e ${SOTA_PACKED_CREDENTIALS} ]; then | 196 | if [ -e ${SOTA_PACKED_CREDENTIALS} ]; then |
192 | garage-push -vv --repo=${OSTREE_REPO} \ | 197 | garage-push -vv --repo=${OSTREE_REPO} \ |
193 | --ref=${OSTREE_BRANCHNAME} \ | 198 | --ref=${OSTREE_BRANCHNAME} \ |
194 | --credentials=${SOTA_PACKED_CREDENTIALS} \ | 199 | --credentials=${SOTA_PACKED_CREDENTIALS} \ |
195 | --cacert=${STAGING_ETCDIR_NATIVE}/ssl/certs/ca-certificates.crt | 200 | --cacert=${STAGING_ETCDIR_NATIVE}/ssl/certs/ca-certificates.crt \ |
201 | $SEND_MANIFEST | ||
196 | else | 202 | else |
197 | bbwarn "SOTA_PACKED_CREDENTIALS file does not exist." | 203 | bbwarn "SOTA_PACKED_CREDENTIALS file does not exist." |
198 | fi | 204 | fi |