Skip to content
Snippets Groups Projects

Submit lava test jobs

Merged Sjoerd Simons requested to merge improve-pipeline into main
4 files
+ 261
64
Compare changes
  • Side-by-side
  • Inline
Files
4
+ 132
37
@@ -11,45 +11,140 @@ image: $DOCKER_IMAGE
stages:
- image
######
# Permissions fixup
#
# GitLab uses a too-lax umask when checking out the repositories, which leads
# to root-owned world-writable files being put in the images.
#
# The image-builder container defaults to umask 022 which would only affects
# the w bit, so reset it for group and other users.
#
# See https://gitlab.com/gitlab-org/gitlab-runner/issues/1736
before_script: &gitlab_permissions_fixup
- chmod -R og-w .
- chmod -R a-w overlays/sudo-fqdn
build image rk3399:
stage: image
stages:
- build
- generate
- lava
.rootfs:
stage: build
before_script: &gitlab_permissions_fixup
- chmod -R og-w .
- chmod -R a-w overlays/sudo-fqdn
script:
- export VERSION="$(date '+%Y%m%d.%H%M%S')"
- mkdir out
- pushd out && debos -t architecture:${ARCHITECTURE} ../ospack.yaml && popd
- 'echo IMAGE_JOB_ID: \"${CI_JOB_ID}\" | tee -a out/image-build-job.yaml'
- 'echo ARCHITECTURE: \"${ARCHITECTURE}\" | tee -a out/image-build-job.yaml'
artifacts:
paths:
- out/*
.kernel:
tags:
- lightweight
variables: &kernel_variables
DEBIAN_FRONTEND: noninteractive
GIT_STRATEGY: none
stage: build
script:
- mkdir dist
- "chdist -d dist create apertis https://repositories.apertis.org/apertis/ v2023pre target"
- cp /etc/apt/trusted.gpg.d/apertis-archive-keyring.gpg dist/apertis/etc/apt/trusted.gpg.d/
- "chdist -d dist -a ${ARCHITECTURE} apt apertis update"
- 'chdist -d dist -a ${ARCHITECTURE} apt apertis download "linux-image-*-${ARCHITECTURE}"'
- dpkg -x *.deb .
- mkdir -p out
- cp -v boot/vmlinuz* out
- if [ -d boot/dtbs ] ; then cp -v boot/dtbs/*/*/*.dtb out ; fi
- depmod -b $(pwd) $(basename $(echo lib/modules/*))
- tar cvzf out/modules.tar.gz lib/modules
- 'echo VMLINUZ: out/vmlinuz* | tee -a out/kernel-build-job.yaml'
- 'echo KERNEL_JOB_ID: \"${CI_JOB_ID}\" | tee -a out/kernel-build-job.yaml'
artifacts:
paths:
- out/*
kernel arm64:
extends: .kernel
variables:
ARCHITECTURE: arm64
<<: *kernel_variables
rootfs arm64:
extends: .rootfs
variables:
ARCHITECTURE: arm64
kernel amd64:
extends: .kernel
variables:
ARCHITECTURE: amd64
<<: *kernel_variables
rootfs amd64:
extends: .rootfs
variables:
ARCHITECTURE: amd64
generate arm64 tests:
stage: generate
tags:
- lightweight
script:
- ./generate_lava_job.py
-e DEVICE_TYPE=bcm2711-rpi-4-b
-e DTB=bcm2711-rpi-4-b.dtb
-e BOOT_METHOD=u-boot
--env-file out/kernel-build-job.yaml
--env-file out/image-build-job.yaml > rpi.yaml
- ./generate_lava_job.py
-e DEVICE_TYPE=rk3399-roc-pc
-e DTB=rk3399-roc-pc.dtb
-e BOOT_METHOD=u-boot
--env-file out/kernel-build-job.yaml
--env-file out/image-build-job.yaml > renegade-elite.yaml
artifacts:
paths:
- "rpi.yaml"
- "renegade-elite.yaml"
needs:
- "rootfs arm64"
- "kernel arm64"
# build ospack
- debos
-t architecture:arm64
-t type:lava
-t suite:$APERTIS_SUITE
-t timestamp:$VERSION
--artifactdir=out
${CI_PROJECT_DIR}/ospack.yaml
# build image
- debos
-t architecture:arm64
-t type:lava
-t suite:$APERTIS_SUITE
-t sbc:roc-pc-rk3399
-t image:lava
--artifactdir=out
${CI_PROJECT_DIR}/image-rk3399.yaml
generate amd64 test:
stage: generate
tags:
- lightweight
script:
- ./generate_lava_job.py
-e DEVICE_TYPE=aaeon-UPN-EHLX4RE-A10-0864
-e BOOT_METHOD=grub
--env-file out/kernel-build-job.yaml
--env-file out/image-build-job.yaml > up-squared.yaml
artifacts:
expire_in: 7d
paths:
- out
- "up-squared.yaml"
needs:
- "rootfs amd64"
- "kernel amd64"
.lavatest:
stage: lava
tags:
- lava-runner
artifacts:
when: always
paths:
- log.yaml
lava test rpi :
extends: .lavatest
script:
- submit rpi.yaml
needs:
- "generate arm64 tests"
lava test renegade elite:
extends: .lavatest
script:
- submit renegade-elite.yaml
needs:
- "generate arm64 tests"
lava test up squared:
extends: .lavatest
script:
- submit up-squared.yaml
needs:
- "generate amd64 test"
Loading