Android backends: Redroid images as components, doctor checks and the setup guide

オープン
#2,052 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
docker, typescript

調査の方向性

Start with #2041 and ADR 0102 §6, then read the named component installer, doctor and Android prerequisite modules, alongside the component and prerequisite tests. The change spans image lifecycle, lease pulls, diagnostics, CLI output, documentation and slow end-to-end coverage; done means the listed unit, typecheck, website build and end-to-end checks pass, including the Linux and Colima setup guide.

索引モデルが issue の本文から書いたものです。

説明

platform:android task:ready

Part of #2041.

Scope

An operator installs, lists and removes Redroid images as components (simlock component install android redroid-34), a lease with an exact model pulls a missing one when downloads are on, and simlock doctor names what keeps Redroid from booting (no docker, a missing context, an engine that is down or not Linux, binder missing or not checkable) with a fix line. The website gains a Redroid setup guide for Linux and Colima.

If it goes wrong, an image in use is removed under a running device, a pull fills the engine's disk with no warning, or doctor sends the operator to the wrong fix.

Technical spec

Commit b037ae2a0.

Rows
  • Behaviours: B21, B22, B23
  • Stored state: S5
  • Interfaces: I13
  • Existing code: X13, X14
Facts
# Fact Source
F1 Doctor's binder check runs docker run --rm alpine:3.20 grep -w binder /proc/filesystems: nodev\tbinder, exit 0, when loaded /private/tmp/claude-501/redroid-design/facts1.log (cited by the parent's I13)
Modules touched

src/drivers/android/redroid/ (components, prerequisites), src/drivers/android/prerequisites.ts, src/core/component-installer.ts, src/core/doctor.ts, src/cli/commands/ (component and doctor output), new website/src/content/docs/docs/worker/redroid.mdx, website/astro.config.mjs (sidebar), website/src/content/docs/docs/worker/runtimes-and-images.mdx, website/src/content/docs/docs/reference/cli.mdx, e2e/slow-android-redroid.test.ts (from #2051; its setup installs through simlock component install). Searches: rg "androidPrerequisites|installComponent|removeComponent" src.

Rules in play
  • ADR 0102 §6: Accepted — not yet implemented; simlock pulls the upstream image and ships none; the operator sets up the engine and binder.
  • ADR 0010: components are installed, recorded and removed only through ComponentInstaller; consent follows downloads.*.
  • src/drivers/AGENTS.md "Prerequisites": the Redroid checks are no Driver method and only doctor runs them.
  • docs/internal/agent-rules/documentation.md rule 9: the setup guide and the CLI reference change in this PR.
Tests

Seam: each row's Seam cell in #2041; model on src/core/component-installer-remove.test.ts, e2e/component-install.test.ts and src/drivers/android/prerequisites.test.ts.

  • B21: A Redroid lease whose image is missing pulls it when downloads are allowed (progress per layer), and records the component; otherwise answers RUNTIME_MISSING naming redroid-<API level>.: downloads on → pull, component.installed; downloads off → RUNTIME_MISSING; tag not found upstream → install failure with the engine's message; second request during the pull joins it; pull past downloads.timeoutMs → the existing timeout error
  • B22: An operator runs simlock component install, list or remove android redroid-34; remove is refused while a device uses it.: install; already installed; list shows redroid-34 with its size; remove; remove in use → COMPONENT_IN_USE; redroid-99 → Unknown component redroid-99; known: redroid-31, redroid-33, redroid-34, redroid-35; redroid-34 on a worker not running Redroid → the same unknown-component refusal
  • B23: simlock doctor on a worker that lists redroid reports what keeps Redroid from booting, with a fix line (I13).: all fine → nothing; docker not found; context not found; engine unreachable; engine not Linux; binder missing; the alpine:3.20 run past its limit, or its pull refused → redroid-binder-unknown; worker that does not list redroid → no Redroid checks

Done when

  • pnpm test:changed and pnpm typecheck pass; each Tests line above is a case table in one test.
  • pnpm test:e2e e2e/component-install.test.ts e2e/component-list.test.ts e2e/component-remove.test.ts still pass: the fake driver keeps the component contract (I12, changed in #2049); Redroid components are proven by the Tests lines above.
  • The website build passes: pnpm --dir website install && pnpm --dir website build && node website/scripts/check-openapi.mjs; worker/redroid.mdx is in the sidebar and gives the Linux and Colima recipes, the provision hook that keeps binder across a VM restart, and the root-equivalence of the docker group.
  • Slow lane, on a Mac with Colima: scripts/slow-e2e.sh e2e/slow-android-redroid.test.ts still passes, its setup now installing each image through simlock component install android redroid-<API level> in place of docker pull.

Out of scope

Disk-space reservation for Redroid pulls (a non-goal of the parent); Docker Desktop, OrbStack and Windows hosts.

Depends on

  • #2051
  • #2049

Written by an agent.

主要言語
TypeScript
スター
730
フォーク
44
平均マージ
15時間 28分
マージ済み PR(30日)
387

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

callstackincubator/simlock のほかの issue

callstackincubator/simlock の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。