From: Henning Schild <henning.schild@siemens.com>
To: <isar-users@googlegroups.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>
Subject: Re: [PATCH 1/2] ci: always test signed and unsigned repo builds
Date: Fri, 15 Nov 2019 18:06:04 +0100 [thread overview]
Message-ID: <20191115180604.6ea2bdcd@md1za8fc.ad001.siemens.net> (raw)
In-Reply-To: <20191115170044.26683-1-henning.schild@siemens.com>
This is not the full test-it all i imagined. But in order to send the
fix ASAP and bring at least some testing, that is what i came up with.
Note if your CI uses "-r -s" you will have to change it! Or this patch
needs a legacy option ignore for the "-s".
Whatever we come up with for this one, the second one is a fix that
probably solves Jans issue. It could potentially be applied before the
testing gets "repaired", but i would like both to be applied. Would
mean we test signed+unsigned but not yet the extra key sources
(DISTRO_BOOTSTRAP_KEYS THIRD_PARTY_APT_KEYS)
Henning
On Fri, 15 Nov 2019 18:00:43 +0100
Henning Schild <henning.schild@siemens.com> wrote:
> From: Henning Schild <henning.schild@siemens.com>
>
> Just split the target set we had into two. Test the first signed and
> the other one unsigned.
>
> Signed-off-by: Henning Schild <henning.schild@siemens.com>
> ---
> scripts/ci_build.sh | 38 +++++++++++++++++++++++---------------
> 1 file changed, 23 insertions(+), 15 deletions(-)
>
> diff --git a/scripts/ci_build.sh b/scripts/ci_build.sh
> index ecaa88a..8295c43 100755
> --- a/scripts/ci_build.sh
> +++ b/scripts/ci_build.sh
> @@ -50,13 +50,14 @@ CROSS_TARGETS_SET="\
> mc:de0-nano-soc-stretch:isar-image-base \
> mc:rpi-stretch:isar-image-base"
>
> -REPRO_TARGETS_SET="\
> +REPRO_TARGETS_SET_SIGNED="\
> mc:qemuarm-stretch:isar-image-base \
> - mc:qemuarm64-stretch:isar-image-base \
> + mc:qemuarm64-stretch:isar-image-base"
> +
> +REPRO_TARGETS_SET="\
> mc:qemuamd64-stretch:isar-image-base \
> mc:qemuarm-buster:isar-image-base"
>
> -
> show_help() {
> echo "This script builds the default Isar images."
> echo
> @@ -70,7 +71,7 @@ show_help() {
> echo " -d, --debug enable debug bitbake output."
> echo " -f, --fast cross build reduced set of
> configurations." echo " -q, --quiet suppress verbose
> bitbake output."
> - echo " -r, --repro [-s, --sign] enable use of cached base
> repository with optional signing."
> + echo " -r, --repro enable use of cached base
> repository." echo " --help display this message
> and exit." echo
> echo "Exit status:"
> @@ -109,9 +110,6 @@ do
> ;;
> -r|--repro)
> REPRO_BUILD="1"
> - case "$2" in
> - -s|--sign) SIGN_REPO='1'; shift ;;
> - esac
> ;;
> *)
> echo "error: invalid parameter '$key', please try '--help'
> to get list of supported parameters" @@ -133,13 +131,24 @@ if [ -n
> "$CROSS_BUILD" ]; then fi
>
> if [ -n "$REPRO_BUILD" ]; then
> - if [ -n "$SIGN_REPO" ]; then
> -
> ISAR_TESTSUITE_GPG_PUB_KEY_FILE="$ISARROOT/testsuite/base-apt/test_pub.key"
> -
> ISAR_TESTSUITE_GPG_PRIV_KEY_FILE="$ISARROOT/testsuite/base-apt/test_priv.key"
> - export GNUPGHOME=$(mktemp -d)
> - gpg --import $ISAR_TESTSUITE_GPG_PUB_KEY_FILE
> $ISAR_TESTSUITE_GPG_PRIV_KEY_FILE
> - echo
> BASE_REPO_KEY=\"file://$ISAR_TESTSUITE_GPG_PUB_KEY_FILE\" >>
> conf/local.conf
> - fi
> +
> ISAR_TESTSUITE_GPG_PUB_KEY_FILE="$ISARROOT/testsuite/base-apt/test_pub.key"
> +
> ISAR_TESTSUITE_GPG_PRIV_KEY_FILE="$ISARROOT/testsuite/base-apt/test_priv.key"
> + export GNUPGHOME=$(mktemp -d)
> + gpg --import $ISAR_TESTSUITE_GPG_PUB_KEY_FILE
> $ISAR_TESTSUITE_GPG_PRIV_KEY_FILE
> +
> + # Enable use of cached base repository
> + echo BASE_REPO_KEY=\"file://$ISAR_TESTSUITE_GPG_PUB_KEY_FILE\"
> >> conf/local.conf
> + bitbake $BB_ARGS -c cache_base_repo $REPRO_TARGETS_SET_SIGNED
> + while [ -e bitbake.sock ]; do sleep 1; done
> + sudo rm -rf tmp
> + sed -i -e 's/#ISAR_USE_CACHED_BASE_REPO ?=
> "1"/ISAR_USE_CACHED_BASE_REPO ?= "1"/g' conf/local.conf
> + bitbake $BB_ARGS $REPRO_TARGETS_SET_SIGNED
> + while [ -e bitbake.sock ]; do sleep 1; done
> + # Cleanup and disable use of cached base repository
> + sudo rm -rf tmp
> + sed -i -e 's/ISAR_USE_CACHED_BASE_REPO ?=
> "1"/#ISAR_USE_CACHED_BASE_REPO ?= "1"/g' conf/local.conf
> + sed -i -e 's/^BASE_REPO_KEY/#BASE_REPO_KEY/g' conf/local.conf
> +
> # Enable use of cached base repository
> bitbake $BB_ARGS -c cache_base_repo $REPRO_TARGETS_SET
> while [ -e bitbake.sock ]; do sleep 1; done
> @@ -150,7 +159,6 @@ if [ -n "$REPRO_BUILD" ]; then
> # Cleanup and disable use of cached base repository
> sudo rm -rf tmp
> sed -i -e 's/ISAR_USE_CACHED_BASE_REPO ?=
> "1"/#ISAR_USE_CACHED_BASE_REPO ?= "1"/g' conf/local.conf
> - sed -i -e 's/^BASE_REPO_KEY/#BASE_REPO_KEY/g' conf/local.conf
> fi
>
> sed -i -e 's/#IMAGE_INSTALL +=
> "isar-disable-apt-cache"/IMAGE_INSTALL += "isar-disable-apt-cache"/g'
> conf/local.conf
next prev parent reply other threads:[~2019-11-15 17:06 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-15 17:00 Henning Schild
2019-11-15 17:00 ` [PATCH 2/2] bootstrap: really fix gpg bootstrap when not signed Henning Schild
2019-11-15 17:06 ` Henning Schild [this message]
2019-11-15 17:08 ` [PATCH 1/2] ci: always test signed and unsigned repo builds Jan Kiszka
2019-11-18 17:05 ` Baurzhan Ismagulov
2019-11-18 17:52 ` Henning Schild
2019-11-19 16:39 ` Baurzhan Ismagulov
2019-11-15 17:21 ` [PATCHv2 " Henning Schild
2019-11-15 17:22 ` Henning Schild
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191115180604.6ea2bdcd@md1za8fc.ad001.siemens.net \
--to=henning.schild@siemens.com \
--cc=isar-users@googlegroups.com \
--cc=jan.kiszka@siemens.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox