All of lore.kernel.org
 help / color / mirror / Atom feed
From: venkata.pyla@toshiba-tsip.com
To: cip-dev@lists.cip-project.org, jan.kiszka@siemens.com
Cc: venkata pyla <venkata.pyla@toshiba-tsip.com>,
	dinesh.kumar@toshiba-tsip.com, kazuhiro3.hayashi@toshiba.co.jp
Subject: [isar-cip-core v3 2/2] .reproducible-check-ci.yml: Add ci for reproducible build checks
Date: Wed, 22 Feb 2023 17:14:08 +0530	[thread overview]
Message-ID: <20230222114408.32155-3-venkata.pyla@toshiba-tsip.com> (raw)
In-Reply-To: <2e6c36f78e3873f0627fa5c3912108fe1283438e.camel@siemens.com>

From: venkata pyla <venkata.pyla@toshiba-tsip.com>

The reproducible check is added only for scheduled CI's in order to reduce
burden on regular commit pushes and monitor only reproducible checks on
specified intervals like bi-weekly or monthly.

Signed-off-by: venkata pyla <venkata.pyla@toshiba-tsip.com>
---
 .gitlab-ci.yml             |  5 +++
 .reproducible-check-ci.yml | 91 ++++++++++++++++++++++++++++++++++++++
 2 files changed, 96 insertions(+)
 create mode 100644 .reproducible-check-ci.yml

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f7c8c88..3642661 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -13,6 +13,7 @@ variables:
 
 stages:
   - build
+  - test
 
 default:
   before_script:
@@ -26,6 +27,8 @@ default:
 
 .build_base:
   stage: build
+  except:
+    - schedules
   tags:
     - large
   variables:
@@ -281,3 +284,5 @@ build:qemu-amd64-secure-boot-buster:
     use_rt: disable
     wic_targz: disable
     deploy: disable
+
+include: '.reproducible-check-ci.yml'
diff --git a/.reproducible-check-ci.yml b/.reproducible-check-ci.yml
new file mode 100644
index 0000000..a50d683
--- /dev/null
+++ b/.reproducible-check-ci.yml
@@ -0,0 +1,91 @@
+# extension to gitlab-ci for reproducible checks
+
+.repro-build:
+  variables:
+    use_rt: disable
+    wic_targz: disable
+    targz: enable
+    deploy: disable
+    deploy_kernelci: disable
+    artifact_suffix: ".tar.gz"
+    base_yaml: "kas-cip.yml:kas/board/${target}.yml"
+  stage: build
+  tags:
+    - large
+  only:
+    - schedules
+  script:
+    - if [ -f kas/opt/reproducible.yml ]; then base_yaml="${base_yaml}:kas/opt/reproducible.yml"; fi
+    # Build 1st time
+    - !reference [.build_base, script]
+    - mv build/tmp/deploy/images/${target}/cip-core-image-cip-core-${release}-${target}${artifact_suffix} image1
+    # clean
+    - sudo rm -rf build/tmp
+    - sudo rm -rf build/sstate-cache
+    # Build 2nd time
+    - !reference [.build_base, script]
+    - mv build/tmp/deploy/images/${target}/cip-core-image-cip-core-${release}-${target}${artifact_suffix} image2
+  artifacts:
+    expire_in: 1 day
+    paths:
+      - image1
+      - image2
+
+.repro-test:
+  image:
+    name: debian:bullseye
+  tags:
+    - large
+  stage: test
+  only:
+    - schedules
+  variables:
+    GIT_STRATEGY: none
+  before_script:
+    - apt update && DEBIAN_FRONTEND=noninteractive apt install -y diffoscope
+  script:
+    - diffoscope --text diffoscope_output.txt image1 image2
+  artifacts:
+    when: always
+    expire_in: 1 day
+    paths:
+      - diffoscope_output.txt
+
+
+# repro build
+build:qemu-amd64-base-repro-build:
+  extends:
+    - .repro-build
+  variables:
+    target: qemu-amd64
+
+build:qemu-arm64-base-repro-build:
+  extends:
+    - .repro-build
+  variables:
+    target: qemu-arm64
+
+build:qemu-arm-base-repro-build:
+  extends:
+    - .repro-build
+  variables:
+    target: qemu-arm
+
+# repro build test
+test:qemu-amd64-base-repro-test:
+  extends:
+    - .repro-test
+  dependencies:
+    - build:qemu-amd64-base-repro-build
+
+test:qemu-arm64-base-repro-test:
+  extends:
+    - .repro-test
+  dependencies:
+    - build:qemu-arm64-base-repro-build
+
+test:qemu-arm-base-repro-test:
+  extends:
+    - .repro-test
+  dependencies:
+    - build:qemu-arm-base-repro-build
-- 
2.20.1




  parent reply	other threads:[~2023-02-22 11:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-22  9:11 [isar-cip-core 0/2] ci for reproducible build check venkata.pyla
2023-02-22  9:11 ` [isar-cip-core 1/2] kas/opt/reproducible.yml: Add kas file for reproducible builds target venkata.pyla
2023-02-22  9:18   ` [cip-dev] " Moessbauer, Felix
2023-02-22 10:56     ` Venkata.Pyla
2023-02-22 11:44     ` [isar-cip-core v3 0/2] ci for reproducible build check venkata.pyla
2023-02-24 17:14       ` Jan Kiszka
2023-02-22 11:44     ` [isar-cip-core v3 1/2] kas/opt/reproducible.yml: Add kas file for reproducible builds target venkata.pyla
2023-02-22 11:44     ` venkata.pyla [this message]
2023-02-24 16:57       ` [isar-cip-core v3 2/2] .reproducible-check-ci.yml: Add ci for reproducible build checks Jan Kiszka
2023-02-22  9:11 ` [isar-cip-core " venkata.pyla

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=20230222114408.32155-3-venkata.pyla@toshiba-tsip.com \
    --to=venkata.pyla@toshiba-tsip.com \
    --cc=cip-dev@lists.cip-project.org \
    --cc=dinesh.kumar@toshiba-tsip.com \
    --cc=jan.kiszka@siemens.com \
    --cc=kazuhiro3.hayashi@toshiba.co.jp \
    /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.