Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Use a distinctive KernelCI shell prompt in rootfs images and LAVA boot templates

Đang mở
#2,922 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
shell
Lĩnh vực
ci-cd, devops, infrastructure

Hướng nghiên cứu

Bắt đầu với config/rootfs/debos/overlays/prompt/root/.profile và config/rootfs/debos/rootfs.yaml, sau đó kiểm tra các template config/runtime/boot được liệt kê để tìm các prompt được hard-code. Chạy các bài kiểm thử render template liên quan và xác minh rằng các job Debos chỉ chọn prompt mới. Công việc được xem là hoàn tất khi đã build lại image Debos, một job QEMU LAVA thành công và có xác thực phần cứng khi cần.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

good first issue

Problem

KernelCI Debos rootfs images currently use a generic shell prompt:

/ #

Some newer images may instead show:

~ #

KernelCI lists these strings as expected login prompts in its LAVA job templates. LAVA warns that these prompts are not distinctive and may accidentally match ordinary boot or status messages:

The string '/ #' does not look like a typical prompt and could match
status messages instead.

Adding ~ # as another accepted prompt prevents login timeouts with newer BusyBox versions, but it does not resolve the warning. LAVA checks every listed prompt and currently considers prompts containing : or \ distinctive.

A false prompt match could cause LAVA to proceed before the device has actually reached a usable shell.

Original example: https://lava.collabora.dev/scheduler/job/19101745#L1878

LAVA prompt validation:

Desired outcome

Use this stable, KernelCI-specific prompt in Debos rootfs images:

PS1='kernelci:$(pwd) # '

At the root directory, it produces:

kernelci:/ #

The prompt is distinctive according to LAVA, unlikely to appear in normal kernel or userspace output, and can be matched exactly by generated LAVA jobs.

Buildroot-based images are outside the scope of this issue and should be handled in a separate follow-up issue because their configuration is maintained in another repository.

Implementation outline

  1. Update the Debos prompt overlay to emit kernelci:$(pwd) # .
  2. Update the LAVA boot templates used with Debos images to expect the new prompt.
  3. Do not list / # or ~ # for images using the new prompt, because LAVA warns about every generic prompt in the list.
  4. If the templates are also used by Buildroot images, make the expected prompt configurable per rootfs or job. Keep the legacy value only for Buildroot until its follow-up issue is completed.
  5. Add or update tests that render the affected templates and verify the prompt selected for a Debos image.
  6. Rebuild a representative Debos rootfs and validate it in a real LAVA job.
  7. Retire Debos images that use the old generic prompt when the new images are published. They do not need to remain compatible after the switch.

Relevant files

  • config/rootfs/debos/overlays/prompt/root/.profile
  • config/rootfs/debos/rootfs.yaml
  • config/runtime/boot/u-boot.jinja2
  • config/runtime/boot/efi.jinja2
  • config/runtime/boot/ipxe.jinja2
  • config/runtime/boot/depthcharge.jinja2
  • config/runtime/boot/fastboot.jinja2
  • config/runtime/boot/qemu.jinja2
  • config/runtime/boot/barebox.jinja2
  • config/runtime/boot/grub.jinja2
  • config/runtime/tests/watchdog-reset.jinja2

The legacy/generated rootfs configuration should also be checked for remaining hard-coded / # values.

Acceptance criteria

  • A newly built representative Debos rootfs displays kernelci:/ # at the root directory on its serial console.
  • Rendered LAVA jobs for Debos images list only prompts those images can emit.
  • LAVA detects the prompt and completes login successfully.
  • The LAVA job does not report the “does not look like a typical prompt” warning for the Debos prompt.
  • At least one QEMU LAVA job is run successfully and linked in this issue.
  • A hardware job is also checked if its prompt or login path differs from QEMU.
  • Debos images using / # or ~ # are retired when the replacement images are published.
  • Buildroot prompt migration is recorded in a separate follow-up issue.
  • Relevant automated tests pass.

Human participation required

This task intentionally needs two short human checkpoints:

  1. A KernelCI maintainer coordinates publication of the replacement Debos image and retirement of the old images.
  2. A lab operator runs a representative LAVA job and confirms from the serial log that the prompt is detected correctly.

These operational steps and the real-lab validation cannot be completed by repository automation alone.

Out of scope

  • Changing LAVA's upstream prompt-validation heuristic.
  • Changing the Buildroot prompt; track this in a follow-up issue.
  • Maintaining compatibility with retired Debos images that use the old prompt.
  • Refactoring unrelated boot or login handling.
  • Redesigning the rootfs publication process.
  • Changing the ChromeOS prompt unless testing shows it is affected.
Ngôn ngữ chính
Python
Star
120
Fork
108
Merge trung bình
1 ngày 12 giờ
Pull request đã merge (30 ngày)
21

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của kernelci/kernelci-core

Tất cả issue của kernelci/kernelci-core

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.