mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 07:20:10 +01:00
ci/lava: Use lava-job-submitter from gfx-ci repo
lava-job-submitter has been moved to a new repository: https://gitlab.freedesktop.org/gfx-ci/lava-job-submitter Switch to using the containers built in that repository. The new lava-trigger container already includes lava-job-submitter pre-installed, along with the new FDO CI bash helpers from ci-templates. Signed-off-by: Valentine Burley <valentine.burley@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37510>
This commit is contained in:
parent
c008d21947
commit
215199af88
2 changed files with 30 additions and 27 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
variables:
|
variables:
|
||||||
LAVA_SSH_CLIENT_IMAGE: "${CI_REGISTRY_IMAGE}/alpine/x86_64_lava_ssh_client:${ALPINE_X86_64_LAVA_SSH_TAG}--${MESA_TEMPLATES_COMMIT}"
|
LAVA_SSH_CLIENT_IMAGE: registry.freedesktop.org/gfx-ci/lava-job-submitter/alpine/x86_64_lava_ssh_client:20250908-lava-ssh
|
||||||
|
|
||||||
|
|
||||||
.lava-test:
|
.lava-test:
|
||||||
|
|
@ -13,7 +13,7 @@ variables:
|
||||||
# 4. lava/health-check-docker - the slim container used for fastboot
|
# 4. lava/health-check-docker - the slim container used for fastboot
|
||||||
# Set image: directly instead of extending .set-image to avoid conflicts
|
# Set image: directly instead of extending .set-image to avoid conflicts
|
||||||
# with MESA_IMAGE_PATH and FDO_DISTRIBUTION_TAG between the containers.
|
# with MESA_IMAGE_PATH and FDO_DISTRIBUTION_TAG between the containers.
|
||||||
image: "${CI_REGISTRY_IMAGE}/alpine/x86_64_lava-trigger:${ALPINE_X86_64_LAVA_TRIGGER_TAG}--${MESA_TEMPLATES_COMMIT}"
|
image: registry.freedesktop.org/gfx-ci/lava-job-submitter/alpine/x86_64_lava-trigger:20250929-lava-timeout
|
||||||
# Cancel job if a newer commit is pushed to the same branch
|
# Cancel job if a newer commit is pushed to the same branch
|
||||||
interruptible: true
|
interruptible: true
|
||||||
# The jobs themselves shouldn't actually run for an hour, of course.
|
# The jobs themselves shouldn't actually run for an hour, of course.
|
||||||
|
|
@ -42,8 +42,17 @@ variables:
|
||||||
S3_RESULTS_UPLOAD: "${JOB_ARTIFACTS_BASE}"
|
S3_RESULTS_UPLOAD: "${JOB_ARTIFACTS_BASE}"
|
||||||
PIGLIT_NO_WINDOW: 1
|
PIGLIT_NO_WINDOW: 1
|
||||||
VISIBILITY_GROUP: "Collabora+fdo"
|
VISIBILITY_GROUP: "Collabora+fdo"
|
||||||
|
# Override the default `before_script` since we don't need to download
|
||||||
|
# setup-test-env.sh.
|
||||||
|
# The LAVA containers already include the necessary FDO CI bash helpers from
|
||||||
|
# ci-templates.
|
||||||
|
before_script:
|
||||||
|
- >
|
||||||
|
export SCRIPTS_DIR=$(mktemp -d) &&
|
||||||
|
curl -L -s --retry 4 -f --retry-all-errors --retry-delay 60 -O --output-dir "${SCRIPTS_DIR}" "${CI_PROJECT_URL}/-/raw/${CI_COMMIT_SHA}/.gitlab-ci/lava/lava-submit.sh"
|
||||||
|
- eval "$S3_JWT_FILE_SCRIPT"
|
||||||
script:
|
script:
|
||||||
- /lava/lava-submit.sh
|
- . ${SCRIPTS_DIR}/lava-submit.sh
|
||||||
artifacts:
|
artifacts:
|
||||||
name: "${CI_PROJECT_NAME}_${CI_JOB_NAME_SLUG}"
|
name: "${CI_PROJECT_NAME}_${CI_JOB_NAME_SLUG}"
|
||||||
when: always
|
when: always
|
||||||
|
|
@ -59,12 +68,6 @@ variables:
|
||||||
- curl -L --retry 4 -f --retry-connrefused --retry-delay 30 -s "https://${JOB_RESULTS_PATH}" | tar --warning=no-timestamp --zstd -x
|
- curl -L --retry 4 -f --retry-connrefused --retry-delay 30 -s "https://${JOB_RESULTS_PATH}" | tar --warning=no-timestamp --zstd -x
|
||||||
needs:
|
needs:
|
||||||
- !reference [.required-for-hardware-jobs, needs]
|
- !reference [.required-for-hardware-jobs, needs]
|
||||||
- job: alpine/x86_64_lava_ssh_client
|
|
||||||
artifacts: false
|
|
||||||
optional: true
|
|
||||||
- job: alpine/x86_64_lava-trigger
|
|
||||||
artifacts: false
|
|
||||||
optional: true
|
|
||||||
|
|
||||||
.lava-x86_64-test:
|
.lava-x86_64-test:
|
||||||
extends:
|
extends:
|
||||||
|
|
|
||||||
|
|
@ -2,21 +2,18 @@
|
||||||
# shellcheck disable=SC2086 # we want word splitting
|
# shellcheck disable=SC2086 # we want word splitting
|
||||||
# shellcheck disable=SC1091 # paths only become valid at runtime
|
# shellcheck disable=SC1091 # paths only become valid at runtime
|
||||||
|
|
||||||
# When changing this file, you need to bump the following
|
# shellcheck disable=SC1090
|
||||||
# .gitlab-ci/image-tags.yml tags:
|
source "${FDO_CI_BASH_HELPERS}"
|
||||||
# ALPINE_X86_64_LAVA_TRIGGER_TAG
|
|
||||||
|
|
||||||
. "${SCRIPTS_DIR}/setup-test-env.sh"
|
fdo_log_section_start_collapsed prepare_rootfs "Preparing root filesystem"
|
||||||
|
|
||||||
section_start prepare_rootfs "Preparing root filesystem"
|
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
# If we run in the fork (not from mesa or Marge-bot), reuse mainline kernel and rootfs, if exist.
|
# If we run in the fork (not from mesa or Marge-bot), reuse mainline kernel and rootfs, if exist.
|
||||||
ROOTFS_URL="$(find_s3_project_artifact "$LAVA_ROOTFS_PATH")" ||
|
ROOTFS_URL="$(fdo_find_s3_path "$LAVA_ROOTFS_PATH")" ||
|
||||||
{
|
{
|
||||||
set +x
|
set +x
|
||||||
error "Sorry, I couldn't find a viable built path for ${LAVA_ROOTFS_PATH} in either mainline or a fork." >&2
|
fdo_log_section_error "Sorry, I couldn't find a viable built path for ${LAVA_ROOTFS_PATH} in either mainline or a fork." >&2
|
||||||
echo "" >&2
|
echo "" >&2
|
||||||
echo "If you're working on CI, this probably means that you're missing a dependency:" >&2
|
echo "If you're working on CI, this probably means that you're missing a dependency:" >&2
|
||||||
echo "this job ran ahead of the job which was supposed to upload that artifact." >&2
|
echo "this job ran ahead of the job which was supposed to upload that artifact." >&2
|
||||||
|
|
@ -31,15 +28,18 @@ ROOTFS_URL="$(find_s3_project_artifact "$LAVA_ROOTFS_PATH")" ||
|
||||||
rm -rf results
|
rm -rf results
|
||||||
mkdir results
|
mkdir results
|
||||||
|
|
||||||
filter_env_vars > dut-env-vars.sh
|
fdo_filter_env_vars > dut-env-vars.sh
|
||||||
# Set SCRIPTS_DIR to point to the Mesa install we download for the DUT
|
# Set SCRIPTS_DIR to point to the Mesa install we download for the DUT
|
||||||
echo "export SCRIPTS_DIR='$CI_PROJECT_DIR/install'" >> dut-env-vars.sh
|
echo "export SCRIPTS_DIR='$CI_PROJECT_DIR/install'" >> dut-env-vars.sh
|
||||||
|
|
||||||
# Prepare env vars for upload.
|
fdo_log_section_end prepare_rootfs
|
||||||
section_switch variables "Environment variables passed through to device:"
|
|
||||||
cat dut-env-vars.sh
|
|
||||||
|
|
||||||
section_switch lava_submit "Submitting job for scheduling"
|
# Prepare env vars for upload.
|
||||||
|
fdo_log_section_start_collapsed variables "Environment variables passed through to device:"
|
||||||
|
cat dut-env-vars.sh
|
||||||
|
fdo_log_section_end variables
|
||||||
|
|
||||||
|
fdo_log_section_start_collapsed lava_submit "Submitting job for scheduling"
|
||||||
|
|
||||||
touch results/lava.log
|
touch results/lava.log
|
||||||
tail -f results/lava.log &
|
tail -f results/lava.log &
|
||||||
|
|
@ -73,7 +73,7 @@ if [ -n "${ANDROID_CTS_TAG:-}" ]; then
|
||||||
LAVA_EXTRA_OVERLAYS+=(
|
LAVA_EXTRA_OVERLAYS+=(
|
||||||
- append-overlay
|
- append-overlay
|
||||||
--name=android-cts
|
--name=android-cts
|
||||||
--url="$(find_s3_project_artifact "${DATA_STORAGE_PATH}/android-cts/${ANDROID_CTS_TAG}.tar.zst")"
|
--url="$(fdo_find_s3_path "${DATA_STORAGE_PATH}/android-cts/${ANDROID_CTS_TAG}.tar.zst")"
|
||||||
--path="/"
|
--path="/"
|
||||||
--format=tar
|
--format=tar
|
||||||
--compression=zstd
|
--compression=zstd
|
||||||
|
|
@ -83,7 +83,7 @@ if [ -n "${FLUSTER_TAG:-}" ]; then
|
||||||
LAVA_EXTRA_OVERLAYS+=(
|
LAVA_EXTRA_OVERLAYS+=(
|
||||||
- append-overlay
|
- append-overlay
|
||||||
--name=vkd3d-proton
|
--name=vkd3d-proton
|
||||||
--url="$(find_s3_project_artifact "${DATA_STORAGE_PATH}/fluster/${FLUSTER_TAG}/vectors.tar.zst")"
|
--url="$(fdo_find_s3_path "${DATA_STORAGE_PATH}/fluster/${FLUSTER_TAG}/vectors.tar.zst")"
|
||||||
--path="/"
|
--path="/"
|
||||||
--format=tar
|
--format=tar
|
||||||
--compression=zstd
|
--compression=zstd
|
||||||
|
|
@ -93,7 +93,7 @@ if [ -n "${VKD3D_PROTON_TAG:-}" ]; then
|
||||||
LAVA_EXTRA_OVERLAYS+=(
|
LAVA_EXTRA_OVERLAYS+=(
|
||||||
- append-overlay
|
- append-overlay
|
||||||
--name=vkd3d-proton
|
--name=vkd3d-proton
|
||||||
--url="$(find_s3_project_artifact "${DATA_STORAGE_PATH}/vkd3d-proton/${VKD3D_PROTON_TAG}/${MESA_IMAGE_PATH}/vkd3d-proton.tar.zst")"
|
--url="$(fdo_find_s3_path "${DATA_STORAGE_PATH}/vkd3d-proton/${VKD3D_PROTON_TAG}/${MESA_IMAGE_PATH}/vkd3d-proton.tar.zst")"
|
||||||
--path="/"
|
--path="/"
|
||||||
--format=tar
|
--format=tar
|
||||||
--compression=zstd
|
--compression=zstd
|
||||||
|
|
@ -126,7 +126,7 @@ if [ -n "${S3_ANDROID_ARTIFACT_NAME:-}" ]; then
|
||||||
)
|
)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
PYTHONPATH=/ /lava/lava_job_submitter.py \
|
lava-job-submitter \
|
||||||
--farm "${FARM}" \
|
--farm "${FARM}" \
|
||||||
--device-type "${DEVICE_TYPE}" \
|
--device-type "${DEVICE_TYPE}" \
|
||||||
--boot-method "${BOOT_METHOD}" \
|
--boot-method "${BOOT_METHOD}" \
|
||||||
|
|
@ -147,7 +147,7 @@ PYTHONPATH=/ /lava/lava_job_submitter.py \
|
||||||
--ssh-client-image "${LAVA_SSH_CLIENT_IMAGE}" \
|
--ssh-client-image "${LAVA_SSH_CLIENT_IMAGE}" \
|
||||||
--project-dir "${CI_PROJECT_DIR}" \
|
--project-dir "${CI_PROJECT_DIR}" \
|
||||||
--project-name "${CI_PROJECT_NAME}" \
|
--project-name "${CI_PROJECT_NAME}" \
|
||||||
--starting-section "${CURRENT_SECTION}" \
|
--starting-section lava_submit \
|
||||||
--job-submitted-at "${CI_JOB_STARTED_AT}" \
|
--job-submitted-at "${CI_JOB_STARTED_AT}" \
|
||||||
- append-overlay \
|
- append-overlay \
|
||||||
--name=mesa-build \
|
--name=mesa-build \
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue