From 3a012ec1d5d7f970c52022b7da5751449693640d Mon Sep 17 00:00:00 2001 From: Phil Wise Date: Fri, 27 Apr 2018 12:26:02 +0200 Subject: Fix permissions of /var/sota in image_types_ota We should also do this in the recipes --- classes/image_types_ota.bbclass | 2 ++ 1 file changed, 2 insertions(+) diff --git a/classes/image_types_ota.bbclass b/classes/image_types_ota.bbclass index d21441d..36e7059 100644 --- a/classes/image_types_ota.bbclass +++ b/classes/image_types_ota.bbclass @@ -105,6 +105,8 @@ IMAGE_CMD_otaimg () { mv ${HOME_TMP}/var/local ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/ || true # Create /var/sota if it doesn't exist yet mkdir -p ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota || true + # Ensure the permissions are correctly set + chmod 700 ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/sota mv ${HOME_TMP}/usr/homedirs/home ${PHYS_SYSROOT}/ || true # Ensure that /var/local exists (AGL symlinks /usr/local to /var/local) install -d ${PHYS_SYSROOT}/ostree/deploy/${OSTREE_OSNAME}/var/local -- cgit v1.2.3-54-g00ecf From 8e77dc5a9adacbca5a4b6e80534972370c000bfa Mon Sep 17 00:00:00 2001 From: Phil Wise Date: Fri, 27 Apr 2018 12:26:58 +0200 Subject: Add missing delay in loop. --- lib/oeqa/selftest/cases/updater.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/lib/oeqa/selftest/cases/updater.py b/lib/oeqa/selftest/cases/updater.py index e459ffb..2ef5a3b 100644 --- a/lib/oeqa/selftest/cases/updater.py +++ b/lib/oeqa/selftest/cases/updater.py @@ -174,12 +174,12 @@ class AutoProvTests(OESelftestTestCase): print(value) print('Checking output of aktualizr-info:') ran_ok = False - for delay in [0, 1, 2, 5, 10, 15]: - sleep(delay) + for delay in [1, 2, 5, 10, 15]: stdout, stderr, retcode = self.qemu_command('aktualizr-info') if retcode == 0 and stderr == b'': ran_ok = True break + sleep(delay) self.assertTrue(ran_ok, 'aktualizr-info failed: ' + stderr.decode() + stdout.decode()) verifyProvisioned(self, machine) @@ -312,12 +312,12 @@ class GrubTests(OESelftestTestCase): print(value) print('Checking output of aktualizr-info:') ran_ok = False - for delay in [0, 1, 2, 5, 10, 15]: - sleep(delay) + for delay in [1, 2, 5, 10, 15]: stdout, stderr, retcode = self.qemu_command('aktualizr-info') if retcode == 0 and stderr == b'': ran_ok = True break + sleep(delay) self.assertTrue(ran_ok, 'aktualizr-info failed: ' + stderr.decode() + stdout.decode()) verifyProvisioned(self, machine) @@ -364,11 +364,12 @@ class ImplProvTests(OESelftestTestCase): print(value) print('Checking output of aktualizr-info:') ran_ok = False - for delay in [0, 1, 2, 5, 10, 15]: + for delay in [1, 2, 5, 10, 15]: stdout, stderr, retcode = self.qemu_command('aktualizr-info') if retcode == 0 and stderr == b'': ran_ok = True break + sleep(delay) self.assertTrue(ran_ok, 'aktualizr-info failed: ' + stderr.decode() + stdout.decode()) # Verify that device has NOT yet provisioned. self.assertIn(b'Couldn\'t load device ID', stdout, @@ -435,11 +436,12 @@ class HsmTests(OESelftestTestCase): print(value) print('Checking output of aktualizr-info:') ran_ok = False - for delay in [0, 1, 2, 5, 10, 15]: + for delay in [1, 2, 5, 10, 15]: stdout, stderr, retcode = self.qemu_command('aktualizr-info') if retcode == 0 and stderr == b'': ran_ok = True break + sleep(delay) self.assertTrue(ran_ok, 'aktualizr-info failed: ' + stderr.decode() + stdout.decode()) # Verify that device has NOT yet provisioned. self.assertIn(b'Couldn\'t load device ID', stdout, -- cgit v1.2.3-54-g00ecf