Skip to content

ci(audience): run StandaloneLinux64 PlayMode on a self-hosted runner (SDK-340)#757

Closed
ImmutableJeffrey wants to merge 3 commits intomainfrom
ci/audience-linux-self-hosted-runner
Closed

ci(audience): run StandaloneLinux64 PlayMode on a self-hosted runner (SDK-340)#757
ImmutableJeffrey wants to merge 3 commits intomainfrom
ci/audience-linux-self-hosted-runner

Conversation

@ImmutableJeffrey
Copy link
Copy Markdown
Collaborator

Summary

  • Folds StandaloneLinux64 into the unified playmode matrix alongside Windows / macOS, pinned to [self-hosted, Linux, X64]. Drops the separate playmode-linux job (the docker + xvfb + watchdog scaffolding from SDK-317 / PR ci(audience): Linux PlayMode runs under xvfb (SDK-317) #754 goes away with it, ~150 lines net).
  • Adds an idempotent in-workflow Install Unity Hub (Linux) step per Unity's Linux install guide. Skips if /opt/unityhub/unityhub already exists, so subsequent runs cost nothing.
  • Adds Resolve Unity (Linux), Run PlayMode tests (Linux), Capture player log (Linux), and Surface Unity compile errors as annotations (Linux) steps modeled directly on the existing macOS pattern.

Why

Unity 6 PlayMode tests on ubuntu-latest-8-cores + Mesa software OpenGL run ~10x slower than on Unity 2021.3 (cells take ~30 min on PR). Real GPU on a self-hosted Linux runner removes the software-rendering bottleneck; cells should land in ~5-10 min like the macOS / Windows desktop cells. SDK-340 has the underlying perf investigation.

Prerequisites on the runner

  1. Passwordless sudo for the runner user (the Hub install step uses sudo apt-get install).
  2. Permanent Unity license activation (UNITY_EMAIL / UNITY_PASSWORD / UNITY_SERIAL activated once on the host so per-cell activation does not eat the seat pool, mirroring the Windows / macOS runners).
  3. Active desktop session with a real GPU. The runner already has both per the runner spec.

Test plan

  • Trigger via workflow_dispatch once Hub is installed; confirm the install step short-circuits on subsequent runs.
  • Confirm linux-il2cpp module installs on the IL2CPP cells; build succeeds.
  • All 39 [UnityTest] cases pass on both backends across Unity 2021.3 / 2022.3 / 6000.4.
  • Cell wall-clock under 15 min on cold cache, under 10 min on warm cache.
  • No regressions on Windows / macOS cells (runner is unchanged for them).

Scope

CI / runner change only. SDK code untouched.

References

ImmutableJeffrey and others added 3 commits May 9, 2026 19:02
… (SDK-340)

- Adds 6 StandaloneLinux64 entries to set-matrix's playmode_full,
  each pinned to [self-hosted, Linux, X64].
- Drops the playmode_linux output and the entire playmode-linux job
  (docker + xvfb + watchdog + ci-provenance scaffolding goes away).
- Adds three Linux steps to the playmode job:
  * Install Unity Hub (idempotent, apt path per
    https://docs.unity.com/en-us/hub/install-hub-linux)
  * Resolve Unity (linux-il2cpp module via Hub headless)
  * Run PlayMode tests (mirrors the macOS step)
- Real GPU + active session means no software OpenGL, no xvfb,
  no minimum-screen workaround. Cells should land in 5-10 min like
  macOS / Windows.

TODO before merge:
- Capture player log (Linux) step (mirror macOS:364-380)
- Surface Unity compile errors as annotations (Linux) step
  (mirror macOS:398-422)
- Confirm Hub install path /opt/unityhub/unityhub matches the apt
  package layout. Adjust if .AppImage chosen instead.
- One smoke run on the runner to verify Hub install + activation +
  editor install all complete cleanly.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Linux pre-checkout step apt-installs git and git-lfs if missing.
- imx-sdkbuild lacked git-lfs, so actions/checkout@v4 with lfs: true
  failed with exit 128: "Unable to locate executable file: git-lfs".
- Idempotent: skips install when both binaries already on PATH.
- Mirrors the Unity Hub install pattern; relies on passwordless sudo
  for the runner user.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Removes "Ensure git and git-lfs (Linux, idempotent)" pre-checkout step.
- Removes "Install Unity Hub (Linux, idempotent)" step.
- Both tools now provisioned on the imx-sdkbuild Linux runner host,
  matching how macOS and Windows self-hosted runners are set up.
- Avoids the unityhub package's interactive debconf prompt that hung
  cell 1 for 20 min before the runner killed it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@ImmutableJeffrey
Copy link
Copy Markdown
Collaborator Author

Closing without merging.

Self-hosted Linux is off the table for the current setup:

  • One self-hosted Linux machine is a bottleneck and contends with other Linux work running on the same host.
  • Latest run hit two host-side issues at once: Unity 2021.3 not installed (Unity $UNITY_VER not found after install) and licensing failed (Code 500: No ULF license found, Token not found in cache).
  • Provisioning the host with every Unity version plus ULF licensing is more operational cost than the speed win justifies.

xvfb path on chore/sdk-318-linux-playmode-xvfb stays the Linux mechanism.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant