summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlbonn <lbonn@users.noreply.github.com>2018-09-27 11:39:06 +0200
committerGitHub <noreply@github.com>2018-09-27 11:39:06 +0200
commita8a112afae60ceec1a2108b8717e9a7bf8080e87 (patch)
tree4ceb8f201ad480219950f1383c933ce1b73f0a4d
parentbc8999428bd73054f1fc71d31315d01b829be04c (diff)
parentd97920396531300644ba27c342644fc08dbf4672 (diff)
downloadmeta-updater-a8a112afae60ceec1a2108b8717e9a7bf8080e87.tar.gz
Merge pull request #395 from advancedtelematic/feat/import-installed-versions-sumo
Feat/import installed versions sumo
-rw-r--r--classes/image_types_ota.bbclass6
-rw-r--r--lib/oeqa/selftest/cases/updater.py4
-rwxr-xr-xrecipes-sota/aktualizr/aktualizr_git.bb2
-rw-r--r--recipes-support/libp11/libp11_0.4.9.bb (renamed from recipes-support/libp11/libp11_0.4.7.bb)10
-rw-r--r--recipes-support/softhsm-testtoken/files/createtoken.sh2
5 files changed, 13 insertions, 11 deletions
diff --git a/classes/image_types_ota.bbclass b/classes/image_types_ota.bbclass
index 360b746..4a51f24 100644
--- a/classes/image_types_ota.bbclass
+++ b/classes/image_types_ota.bbclass
@@ -99,7 +99,7 @@ IMAGE_CMD_otaimg () {
99 99
100 cp -a ${IMAGE_ROOTFS}/var/sota ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/ || true 100 cp -a ${IMAGE_ROOTFS}/var/sota ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/ || true
101 # Create /var/sota if it doesn't exist yet 101 # Create /var/sota if it doesn't exist yet
102 mkdir -p ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota || true 102 mkdir -p ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota
103 # Ensure the permissions are correctly set 103 # Ensure the permissions are correctly set
104 chmod 700 ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota 104 chmod 700 ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota
105 105
@@ -112,7 +112,9 @@ IMAGE_CMD_otaimg () {
112 if [ -n "${GARAGE_TARGET_VERSION}" ]; then 112 if [ -n "${GARAGE_TARGET_VERSION}" ]; then
113 target_version=${GARAGE_TARGET_VERSION} 113 target_version=${GARAGE_TARGET_VERSION}
114 fi 114 fi
115 echo "{\"${ostree_target_hash}\":\"${GARAGE_TARGET_NAME}-${target_version}\"}" > ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota/installed_versions 115 mkdir -p ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota/import
116 echo "{\"${ostree_target_hash}\":\"${GARAGE_TARGET_NAME}-${target_version}\"}" > ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota/import/installed_versions
117
116 rm -rf ${HOME_TMP} 118 rm -rf ${HOME_TMP}
117 119
118 # Calculate image type 120 # Calculate image type
diff --git a/lib/oeqa/selftest/cases/updater.py b/lib/oeqa/selftest/cases/updater.py
index 1c5a1dc..a3fe407 100644
--- a/lib/oeqa/selftest/cases/updater.py
+++ b/lib/oeqa/selftest/cases/updater.py
@@ -226,8 +226,8 @@ class ManualControlTests(OESelftestTestCase):
226 Disable the systemd service then run aktualizr manually 226 Disable the systemd service then run aktualizr manually
227 """ 227 """
228 sleep(20) 228 sleep(20)
229 stdout, stderr, retcode = self.qemu_command('aktualizr-info --allow-migrate') 229 stdout, stderr, retcode = self.qemu_command('aktualizr-info')
230 self.assertIn(b'Fetched metadata: no', stdout, 230 self.assertIn(b'Can\'t open database', stdout,
231 'Aktualizr should not have run yet' + stderr.decode() + stdout.decode()) 231 'Aktualizr should not have run yet' + stderr.decode() + stdout.decode())
232 232
233 stdout, stderr, retcode = self.qemu_command('aktualizr --running-mode=once') 233 stdout, stderr, retcode = self.qemu_command('aktualizr --running-mode=once')
diff --git a/recipes-sota/aktualizr/aktualizr_git.bb b/recipes-sota/aktualizr/aktualizr_git.bb
index fd2fdd5..7260af6 100755
--- a/recipes-sota/aktualizr/aktualizr_git.bb
+++ b/recipes-sota/aktualizr/aktualizr_git.bb
@@ -26,7 +26,7 @@ SRC_URI = " \
26 file://aktualizr-secondary.socket \ 26 file://aktualizr-secondary.socket \
27 file://aktualizr-serialcan.service \ 27 file://aktualizr-serialcan.service \
28 " 28 "
29SRCREV = "8083d4fa67046689d4bf784b908a048a58457d63" 29SRCREV = "487905ccb2a4b7e8b01becd051242fe504e85950"
30BRANCH ?= "master" 30BRANCH ?= "master"
31 31
32S = "${WORKDIR}/git" 32S = "${WORKDIR}/git"
diff --git a/recipes-support/libp11/libp11_0.4.7.bb b/recipes-support/libp11/libp11_0.4.9.bb
index 02d9e50..6d0165f 100644
--- a/recipes-support/libp11/libp11_0.4.7.bb
+++ b/recipes-support/libp11/libp11_0.4.9.bb
@@ -11,14 +11,14 @@ RDEPENDS_${PN} += " opensc"
11 11
12SRC_URI = "git://github.com/OpenSC/libp11.git \ 12SRC_URI = "git://github.com/OpenSC/libp11.git \
13 file://0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch" 13 file://0001-Workaround-for-a-buggy-version-of-openssl-1.0.2m.patch"
14SRCREV = "da725ab727342083478150a203a3c80c4551feb4" 14SRCREV = "e1210903291b1de9eabcad26e740a4b2fbcca692"
15 15
16S = "${WORKDIR}/git" 16S = "${WORKDIR}/git"
17 17
18inherit autotools pkgconfig 18inherit autotools pkgconfig
19 19
20# Currently, Makefile dependencies are incorrectly defined which causes build errors 20# Currently, Makefile dependencies are incorrectly defined which causes build errors
21# The number of jobs is high 21# if the number of jobs is high
22# See https://github.com/OpenSC/libp11/issues/94 22# See https://github.com/OpenSC/libp11/issues/94
23PARALLEL_MAKE = "" 23PARALLEL_MAKE = ""
24EXTRA_OECONF = "--disable-static" 24EXTRA_OECONF = "--disable-static"
@@ -28,12 +28,12 @@ do_install_append () {
28 rm -rf ${D}${docdir}/${BPN} 28 rm -rf ${D}${docdir}/${BPN}
29} 29}
30 30
31FILES_${PN} = "${libdir}/engines/pkcs11.so \ 31FILES_${PN} = "${libdir}/engines*/pkcs11.so \
32 ${libdir}/engines/libpkcs11${SOLIBS} \ 32 ${libdir}/engines*/libpkcs11${SOLIBS} \
33 ${libdir}/libp11${SOLIBS}" 33 ${libdir}/libp11${SOLIBS}"
34 34
35FILES_${PN}-dev = " \ 35FILES_${PN}-dev = " \
36 ${libdir}/engines/libpkcs11${SOLIBSDEV} \ 36 ${libdir}/engines*/libpkcs11${SOLIBSDEV} \
37 ${libdir}/libp11${SOLIBSDEV} \ 37 ${libdir}/libp11${SOLIBSDEV} \
38 ${libdir}/pkgconfig/libp11.pc \ 38 ${libdir}/pkgconfig/libp11.pc \
39 /usr/include" 39 /usr/include"
diff --git a/recipes-support/softhsm-testtoken/files/createtoken.sh b/recipes-support/softhsm-testtoken/files/createtoken.sh
index 5c67080..b142945 100644
--- a/recipes-support/softhsm-testtoken/files/createtoken.sh
+++ b/recipes-support/softhsm-testtoken/files/createtoken.sh
@@ -5,7 +5,7 @@ if pkcs11-tool --module=/usr/lib/softhsm/libsofthsm2.so -O; then
5 exit 0 5 exit 0
6fi 6fi
7 7
8if ! ls /var/sota/import/pkey.pem /var/sota/import/client.pem /var/sota/import/pkey.pem; then 8if ! ls /var/sota/import/pkey.pem /var/sota/import/client.pem; then
9 # Key/certificate pair is not present, repeat 9 # Key/certificate pair is not present, repeat
10 exit 1 10 exit 1
11fi 11fi