All of lore.kernel.org
 help / color / mirror / Atom feed
From: Quirin.Gylstorff@siemens.com (Q. Gylstorff)
To: cip-dev@lists.cip-project.org
Subject: [cip-dev] [isar-cip-core PATCH v2 2/4] classes: add wic-targz-img.bbclass
Date: Thu,  7 Nov 2019 17:39:40 +0100	[thread overview]
Message-ID: <20191107163942.23513-3-Quirin.Gylstorff@siemens.com> (raw)
In-Reply-To: <TYAPR01MB2285BB4C180DBB805DC1C079B7790@TYAPR01MB2285.jpnprd01.prod.outlook.com>

From: Quirin Gylstorff <quirin.gylstorff@siemens.com>

The Linaro Automated Validation Architecture (LAVA) uses tarballs
as root file-systems to modify the file-system during the deployment.
Add a new bbclass to build tarballs and wic images at the same time to
feed the build output of isar-cip-core directly into LAVA tests.

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@siemens.com>
---
 classes/wic-targz-img.bbclass     | 13 +++++++++++++
 conf/machine/bbb.conf             |  2 +-
 conf/machine/iwg20m.conf          |  2 +-
 conf/machine/qemu-amd64.conf      |  2 +-
 conf/machine/simatic-ipc227e.conf |  2 +-
 opt-targz-img.yml                 | 20 ++++++++++++++++++++
 scripts/deploy-cip-core.sh        |  4 ++++
 7 files changed, 41 insertions(+), 4 deletions(-)
 create mode 100644 classes/wic-targz-img.bbclass
 create mode 100644 opt-targz-img.yml

diff --git a/classes/wic-targz-img.bbclass b/classes/wic-targz-img.bbclass
new file mode 100644
index 0000000..4e9f89d
--- /dev/null
+++ b/classes/wic-targz-img.bbclass
@@ -0,0 +1,13 @@
+#
+# CIP Core, generic profile
+#
+# Copyright (c) Siemens AG, 2019
+#
+# Authors:
+#  Quirin Gylstorff <quirin.gylstorff@siemens.com>
+#
+# SPDX-License-Identifier: MIT
+#
+
+inherit wic-img
+inherit targz-img
diff --git a/conf/machine/bbb.conf b/conf/machine/bbb.conf
index c945aac..a9b460e 100644
--- a/conf/machine/bbb.conf
+++ b/conf/machine/bbb.conf
@@ -8,7 +8,7 @@
 
 DISTRO_ARCH = "armhf"
 
-IMAGE_TYPE = "wic-img"
+IMAGE_TYPE ?= "wic-img"
 IMAGER_INSTALL += "u-boot-omap"
 
 # On stretch, select U-Boot from buster which comes with distro-boot support
diff --git a/conf/machine/iwg20m.conf b/conf/machine/iwg20m.conf
index 2f91771..6c1a227 100644
--- a/conf/machine/iwg20m.conf
+++ b/conf/machine/iwg20m.conf
@@ -8,7 +8,7 @@
 DISTRO_ARCH = "armhf"
 
 # see wic/iwg20m.wks
-IMAGE_TYPE = "wic-img"
+IMAGE_TYPE ?= "wic-img"
 
 # sets serial login getty
 MACHINE_SERIAL = "ttySC0"
diff --git a/conf/machine/qemu-amd64.conf b/conf/machine/qemu-amd64.conf
index 90325d6..7cbd55b 100644
--- a/conf/machine/qemu-amd64.conf
+++ b/conf/machine/qemu-amd64.conf
@@ -8,4 +8,4 @@
 
 DISTRO_ARCH = "amd64"
 
-IMAGE_TYPE = "ext4-img"
+IMAGE_TYPE ?= "ext4-img"
diff --git a/conf/machine/simatic-ipc227e.conf b/conf/machine/simatic-ipc227e.conf
index 73dac33..473e6c5 100644
--- a/conf/machine/simatic-ipc227e.conf
+++ b/conf/machine/simatic-ipc227e.conf
@@ -8,5 +8,5 @@
 
 DISTRO_ARCH = "amd64"
 
-IMAGE_TYPE = "wic-img"
+IMAGE_TYPE ?= "wic-img"
 IMAGER_INSTALL += "${GRUB_BOOTLOADER_INSTALL}"
diff --git a/opt-targz-img.yml b/opt-targz-img.yml
new file mode 100644
index 0000000..1a73024
--- /dev/null
+++ b/opt-targz-img.yml
@@ -0,0 +1,20 @@
+#
+# CIP Core, generic profile
+#
+# Copyright (c) Siemens AG, 2019
+#
+# Authors:
+#  Quirin Gylstorff <quirin.gylstorff@siemens.com>
+#
+# SPDX-License-Identifier: MIT
+#
+
+header:
+  version: 8
+
+# lava uses nfs to deploy the image. For this we need a tarball instead of
+# full image
+
+local_conf_header:
+  image-type: |
+    IMAGE_TYPE = "wic-targz-img"
diff --git a/scripts/deploy-cip-core.sh b/scripts/deploy-cip-core.sh
index 081dc9d..e5c09ef 100755
--- a/scripts/deploy-cip-core.sh
+++ b/scripts/deploy-cip-core.sh
@@ -26,6 +26,10 @@ xz -9 -k $BASE_PATH.wic.img
 echo "Uploading artifacts..."
 aws s3 cp --no-progress $BASE_PATH.wic.img.xz s3://download.cip-project.org/cip-core/$TARGET/
 
+if [ -f $BASE_PATH.tar.gz ]; then
+    aws s3 cp --no-progress $BASE_PATH.tar.gz s3://download.cip-project.org/cip-core/$TARGET/
+fi
+
 KERNEL_IMAGE=$BASE_PATH-vmlinuz
 # iwg20m workaround
 if [ -f build/tmp/deploy/images/$TARGET/zImage ]; then
-- 
2.20.1

  parent reply	other threads:[~2019-11-07 16:39 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-06 12:44 [cip-dev] [isar-cip-core PATCH 0/4] Add rzg2m support Q. Gylstorff
2019-11-06 12:44 ` [cip-dev] [isar-cip-core PATCH 1/4] kas: Increase Isar version Q. Gylstorff
2019-11-06 12:44 ` [cip-dev] [isar-cip-core PATCH 2/4] classes: add wic-targz-img.bbclass Q. Gylstorff
2019-11-06 12:44 ` [cip-dev] [isar-cip-core PATCH 3/4] hihope-rzg2m: Add board support Q. Gylstorff
2019-11-06 15:38   ` Chris Paterson
2019-11-06 15:53     ` Gylstorff Quirin
2019-11-07  2:29       ` kazuhiro3.hayashi at toshiba.co.jp
2019-11-07 15:53         ` Gylstorff Quirin
2019-11-08 21:29           ` Pavel Machek
2019-11-11  6:18           ` kazuhiro3.hayashi at toshiba.co.jp
2019-11-06 12:44 ` [cip-dev] [isar-cip-core PATCH 4/4] ci: add hihope-rzg2m to ci chain Q. Gylstorff
2019-11-06 15:43   ` Chris Paterson
2019-11-07 16:39     ` [cip-dev] [isar-cip-core PATCH v2 0/4] Add rzg2m support Q. Gylstorff
2019-11-22  7:22       ` Jan Kiszka
2019-11-07 16:39     ` [cip-dev] [isar-cip-core PATCH v2 1/4] kas: Increase Isar version Q. Gylstorff
2019-11-07 16:39     ` Q. Gylstorff [this message]
2019-11-07 16:39     ` [cip-dev] [isar-cip-core PATCH v2 3/4] hihope-rzg2m: Add board support Q. Gylstorff
2019-11-07 16:39     ` [cip-dev] [isar-cip-core PATCH v2 4/4] ci: add hihope-rzg2m to ci chain Q. Gylstorff
2019-11-06 14:12 ` [cip-dev] [isar-cip-core PATCH 0/4] Add rzg2m support Jan Kiszka
2019-11-06 14:37   ` Gylstorff Quirin
2019-11-06 16:19     ` Chris Paterson
2019-11-08 12:57       ` Gylstorff Quirin

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=20191107163942.23513-3-Quirin.Gylstorff@siemens.com \
    --to=quirin.gylstorff@siemens.com \
    --cc=cip-dev@lists.cip-project.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.