diff options
-rw-r--r-- | .gitlab-ci.yml | 2 | ||||
-rw-r--r-- | classes/image_types_ostree.bbclass | 6 | ||||
-rw-r--r-- | classes/sota.bbclass | 1 | ||||
-rw-r--r-- | lib/oeqa/selftest/cases/updater_qemux86_64_ptest.py | 4 | ||||
-rw-r--r-- | recipes-connectivity/openssl/files/0001-Fix-broken-change-from-b3d113e.patch | 29 | ||||
-rw-r--r-- | recipes-connectivity/openssl/openssl_1.1.1c.bbappend | 4 | ||||
-rw-r--r-- | recipes-sota/aktualizr/aktualizr_git.bb | 4 | ||||
-rwxr-xr-x | scripts/ci/checkout-oe.sh | 7 | ||||
-rwxr-xr-x | scripts/ci/oe-selftest.sh | 5 |
9 files changed, 55 insertions, 7 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3682753..4b22e20 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml | |||
@@ -77,7 +77,7 @@ Oe-selftest rpi: | |||
77 | stage: test | 77 | stage: test |
78 | variables: | 78 | variables: |
79 | TEST_BUILD_DIR: 'build-oe-rpi' | 79 | TEST_BUILD_DIR: 'build-oe-rpi' |
80 | OE_SELFTESTS: 'updater_rpi' | 80 | OE_SELFTESTS: 'updater_raspberrypi' |
81 | except: | 81 | except: |
82 | - pushes | 82 | - pushes |
83 | only: | 83 | only: |
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index c9173d4..5b975f0 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -231,6 +231,12 @@ IMAGE_CMD_garagesign () { | |||
231 | ${target_url} \ | 231 | ${target_url} \ |
232 | --sha256 ${ostree_target_hash} \ | 232 | --sha256 ${ostree_target_hash} \ |
233 | --hardwareids ${SOTA_HARDWARE_ID} | 233 | --hardwareids ${SOTA_HARDWARE_ID} |
234 | if [ -n "${GARAGE_CUSTOMIZE_TARGET}" ]; then | ||
235 | bbplain "Running command(${GARAGE_CUSTOMIZE_TARGET}) to customize target" | ||
236 | ${GARAGE_CUSTOMIZE_TARGET} \ | ||
237 | ${GARAGE_SIGN_REPO}/tufrepo/roles/unsigned/targets.json \ | ||
238 | ${GARAGE_TARGET_NAME}-${target_version} | ||
239 | fi | ||
234 | garage-sign targets sign --repo tufrepo \ | 240 | garage-sign targets sign --repo tufrepo \ |
235 | --home-dir ${GARAGE_SIGN_REPO} \ | 241 | --home-dir ${GARAGE_SIGN_REPO} \ |
236 | --key-name=targets | 242 | --key-name=targets |
diff --git a/classes/sota.bbclass b/classes/sota.bbclass index 743bd3b..1a9d68b 100644 --- a/classes/sota.bbclass +++ b/classes/sota.bbclass | |||
@@ -49,6 +49,7 @@ GARAGE_SIGN_REPO ?= "${DEPLOY_DIR_IMAGE}/garage_sign_repo" | |||
49 | GARAGE_SIGN_KEYNAME ?= "garage-key" | 49 | GARAGE_SIGN_KEYNAME ?= "garage-key" |
50 | GARAGE_TARGET_VERSION ?= "" | 50 | GARAGE_TARGET_VERSION ?= "" |
51 | GARAGE_TARGET_URL ?= "" | 51 | GARAGE_TARGET_URL ?= "" |
52 | GARAGE_CUSTOMIZE_TARGET ?= "" | ||
52 | 53 | ||
53 | SOTA_MACHINE ??="none" | 54 | SOTA_MACHINE ??="none" |
54 | SOTA_MACHINE_rpi ?= "raspberrypi" | 55 | SOTA_MACHINE_rpi ?= "raspberrypi" |
diff --git a/lib/oeqa/selftest/cases/updater_qemux86_64_ptest.py b/lib/oeqa/selftest/cases/updater_qemux86_64_ptest.py index e9a1a65..d20a9f0 100644 --- a/lib/oeqa/selftest/cases/updater_qemux86_64_ptest.py +++ b/lib/oeqa/selftest/cases/updater_qemux86_64_ptest.py | |||
@@ -21,7 +21,7 @@ class PtestTests(OESelftestTestCase): | |||
21 | self.append_config('PTEST_ENABLED_pn-aktualizr = "1"') | 21 | self.append_config('PTEST_ENABLED_pn-aktualizr = "1"') |
22 | self.append_config('IMAGE_INSTALL_append += "aktualizr-ptest ptest-runner "') | 22 | self.append_config('IMAGE_INSTALL_append += "aktualizr-ptest ptest-runner "') |
23 | self.append_config('IMAGE_FSTYPES_remove = "ostreepush garagesign garagecheck"') | 23 | self.append_config('IMAGE_FSTYPES_remove = "ostreepush garagesign garagecheck"') |
24 | self.qemu, self.s = qemu_launch(machine='qemux86-64', mem="256M") | 24 | self.qemu, self.s = qemu_launch(machine='qemux86-64', mem="768M") |
25 | 25 | ||
26 | def tearDownLocal(self): | 26 | def tearDownLocal(self): |
27 | qemu_terminate(self.s) | 27 | qemu_terminate(self.s) |
@@ -41,7 +41,7 @@ class PtestTests(OESelftestTestCase): | |||
41 | if has_failure: | 41 | if has_failure: |
42 | print("Full test suite log:") | 42 | print("Full test suite log:") |
43 | stdout, _, _ = self.qemu_command('cat /tmp/aktualizr-ptest.log || cat /tmp/aktualizr-ptest.log.tmp', timeout=None) | 43 | stdout, _, _ = self.qemu_command('cat /tmp/aktualizr-ptest.log || cat /tmp/aktualizr-ptest.log.tmp', timeout=None) |
44 | print(stdout.decode()) | 44 | print(stdout.decode(errors='replace')) |
45 | 45 | ||
46 | self.assertEqual(retcode, 0) | 46 | self.assertEqual(retcode, 0) |
47 | self.assertFalse(has_failure) | 47 | self.assertFalse(has_failure) |
diff --git a/recipes-connectivity/openssl/files/0001-Fix-broken-change-from-b3d113e.patch b/recipes-connectivity/openssl/files/0001-Fix-broken-change-from-b3d113e.patch new file mode 100644 index 0000000..b176cc7 --- /dev/null +++ b/recipes-connectivity/openssl/files/0001-Fix-broken-change-from-b3d113e.patch | |||
@@ -0,0 +1,29 @@ | |||
1 | From 711a161f03ef9ed7cd149a22bf1203700c103e96 Mon Sep 17 00:00:00 2001 | ||
2 | From: Pauli <paul.dale@oracle.com> | ||
3 | Date: Fri, 29 Mar 2019 09:24:07 +1000 | ||
4 | Subject: [PATCH] Fix broken change from b3d113e. | ||
5 | |||
6 | Reviewed-by: Tim Hudson <tjh@openssl.org> | ||
7 | (Merged from https://github.com/openssl/openssl/pull/8606) | ||
8 | --- | ||
9 | crypto/rand/rand_lib.c | 3 ++- | ||
10 | 1 file changed, 2 insertions(+), 1 deletion(-) | ||
11 | |||
12 | diff --git a/crypto/rand/rand_lib.c b/crypto/rand/rand_lib.c | ||
13 | index 23abbde156..a298b7515b 100644 | ||
14 | --- a/crypto/rand/rand_lib.c | ||
15 | +++ b/crypto/rand/rand_lib.c | ||
16 | @@ -235,8 +235,9 @@ size_t rand_drbg_get_nonce(RAND_DRBG *drbg, | ||
17 | struct { | ||
18 | void * instance; | ||
19 | int count; | ||
20 | - } data = { NULL, 0 }; | ||
21 | + } data; | ||
22 | |||
23 | + memset(&data, 0, sizeof(data)); | ||
24 | pool = rand_pool_new(0, min_len, max_len); | ||
25 | if (pool == NULL) | ||
26 | return 0; | ||
27 | -- | ||
28 | 2.20.1 | ||
29 | |||
diff --git a/recipes-connectivity/openssl/openssl_1.1.1c.bbappend b/recipes-connectivity/openssl/openssl_1.1.1c.bbappend new file mode 100644 index 0000000..85fca9b --- /dev/null +++ b/recipes-connectivity/openssl/openssl_1.1.1c.bbappend | |||
@@ -0,0 +1,4 @@ | |||
1 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" | ||
2 | |||
3 | # from https://github.com/openssl/openssl/pull/8606 | ||
4 | SRC_URI += "file://0001-Fix-broken-change-from-b3d113e.patch" | ||
diff --git a/recipes-sota/aktualizr/aktualizr_git.bb b/recipes-sota/aktualizr/aktualizr_git.bb index 5de341e..e9efa35 100644 --- a/recipes-sota/aktualizr/aktualizr_git.bb +++ b/recipes-sota/aktualizr/aktualizr_git.bb | |||
@@ -10,7 +10,7 @@ DEPENDS_append = "${@bb.utils.contains('PTEST_ENABLED', '1', ' coreutils-native | |||
10 | RDEPENDS_${PN}_class-target = "aktualizr-configs lshw" | 10 | RDEPENDS_${PN}_class-target = "aktualizr-configs lshw" |
11 | RDEPENDS_${PN}-host-tools = "aktualizr aktualizr-repo aktualizr-cert-provider ${@bb.utils.contains('PACKAGECONFIG', 'sota-tools', 'garage-deploy garage-push', '', d)}" | 11 | RDEPENDS_${PN}-host-tools = "aktualizr aktualizr-repo aktualizr-cert-provider ${@bb.utils.contains('PACKAGECONFIG', 'sota-tools', 'garage-deploy garage-push', '', d)}" |
12 | 12 | ||
13 | RDEPENDS_${PN}-ptest += "bash cmake curl python3-misc python3-modules openssl-bin sqlite3 valgrind" | 13 | RDEPENDS_${PN}-ptest += "bash cmake curl net-tools python3-misc python3-modules openssl-bin sqlite3 valgrind" |
14 | 14 | ||
15 | PV = "1.0+git${SRCPV}" | 15 | PV = "1.0+git${SRCPV}" |
16 | PR = "7" | 16 | PR = "7" |
@@ -31,7 +31,7 @@ SRC_URI = " \ | |||
31 | SRC_URI[md5sum] = "e104ccd4f32e52571a5fc0e5042db050" | 31 | SRC_URI[md5sum] = "e104ccd4f32e52571a5fc0e5042db050" |
32 | SRC_URI[sha256sum] = "c590be1a57523bfe097af82279eda5c97cf40ae47fb27162cf33c469702c8a9b" | 32 | SRC_URI[sha256sum] = "c590be1a57523bfe097af82279eda5c97cf40ae47fb27162cf33c469702c8a9b" |
33 | 33 | ||
34 | SRCREV = "9c592cf9d8dfcd995d47753f2be7bd1a2b56c7da" | 34 | SRCREV = "17c3713fb3085fe5459ac0e8244a2047d55cb7ec" |
35 | BRANCH ?= "master" | 35 | BRANCH ?= "master" |
36 | 36 | ||
37 | S = "${WORKDIR}/git" | 37 | S = "${WORKDIR}/git" |
diff --git a/scripts/ci/checkout-oe.sh b/scripts/ci/checkout-oe.sh index a99f235..fdc0e48 100755 --- a/scripts/ci/checkout-oe.sh +++ b/scripts/ci/checkout-oe.sh | |||
@@ -19,9 +19,11 @@ mkdir -p updater-repo | |||
19 | 19 | ||
20 | cd updater-repo | 20 | cd updater-repo |
21 | 21 | ||
22 | repo init -m "${MANIFEST}.xml" -u "$REMOTE_SOURCE/updater-repo" | 22 | if [ -d .repo/manifests ]; then |
23 | git -C .repo/manifests reset --hard | ||
24 | fi | ||
23 | 25 | ||
24 | git -C .repo/manifests reset --hard | 26 | repo init -m "${MANIFEST}.xml" -u "$REMOTE_SOURCE/updater-repo" |
25 | 27 | ||
26 | # patch manifest: | 28 | # patch manifest: |
27 | # - add a new "ats" remote that points to "$REMOTE_SOURCE" | 29 | # - add a new "ats" remote that points to "$REMOTE_SOURCE" |
@@ -45,6 +47,7 @@ for pin in $PIN_LIST; do | |||
45 | IFS=":" | 47 | IFS=":" |
46 | read -r project rev <<< "$pin" | 48 | read -r project rev <<< "$pin" |
47 | xmlstarlet ed --omit-decl -L \ | 49 | xmlstarlet ed --omit-decl -L \ |
50 | -d "/manifest/project[@name=\"$project\"]/@revision" \ | ||
48 | -i "/manifest/project[@name=\"$project\"]/@revision" -t attr -n "revision" -v "$rev" \ | 51 | -i "/manifest/project[@name=\"$project\"]/@revision" -t attr -n "revision" -v "$rev" \ |
49 | -i "/manifest/project[@name=\"$project\"]" -t attr -n "revision" -v "$rev" \ | 52 | -i "/manifest/project[@name=\"$project\"]" -t attr -n "revision" -v "$rev" \ |
50 | "$MANIFEST_FILE" | 53 | "$MANIFEST_FILE" |
diff --git a/scripts/ci/oe-selftest.sh b/scripts/ci/oe-selftest.sh index 66b1fc9..178e7c1 100755 --- a/scripts/ci/oe-selftest.sh +++ b/scripts/ci/oe-selftest.sh | |||
@@ -17,5 +17,10 @@ export METADIR | |||
17 | . "${TEST_REPO_DIR}/meta-updater/scripts/envsetup.sh" "${TEST_MACHINE}" "${TEST_BUILD_DIR}" | 17 | . "${TEST_REPO_DIR}/meta-updater/scripts/envsetup.sh" "${TEST_MACHINE}" "${TEST_BUILD_DIR}" |
18 | 18 | ||
19 | set -x | 19 | set -x |
20 | |||
21 | # work poky around bug on sumo and thud | ||
22 | # see https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=d3a94e5b9b3c107cf54d5639071cc6609c002f67 | ||
23 | mkdir -p "tmp/log" | ||
24 | |||
20 | oe-selftest -r "$@" | 25 | oe-selftest -r "$@" |
21 | ) | 26 | ) |