MONKEYTESTERDOCS
Docs / Lab inventory

The current lab setup

Exactly what runs where today, read from the live machines. Use it as the target state when you rebuild the lab, and as a checklist when something stops working.

Machines

MachineRoleRuns
Linux host
192.168.125.70
Viewer, loopback plugins, source controlMonkeyTester viewer :8089 · DIFF plugin :8095 · ESP32-SENSOR plugin :8091 and ESP32-SERVER plugin :8093 (all loopback; the server plugin's fake hub :8092 on the LAN) · Gitea :3000 (SSH :2222) · this website :8001
Mac
192.168.125.71
Apple silicon, macOS 27.2, Xcode 27.2
Phones, vision model, app buildsMobile Controller :8090 (starts Appium :4723) · AI plugin :8091 (private Ollama :11435) · build-local build plugin :8094 (Gitea code host) · build-github build plugin :8095 (GitHub code host)

Devices

DeviceAttached toIdNotes
iPhone SEMac, USB00008030-000C50D42EE3802ETrusted, Developer Mode on, kept unlocked and awake. Screen class 375x667@2x.
moto g power (2025)Mac (adb)ZA2235GDS8USB or wireless debugging paired with the Mac.

Services on the Linux host

All are systemd user units (systemctl --user …) under the server account, enabled at login. Enable lingering (loginctl enable-linger server) so they start at boot without a login.

UnitWorking directoryStart command
monkeytester-viewer~/workspace/MonkeyTester/MonkeyTester/usr/bin/python3 app.py 8089
monkeytester-diffthe MonkeyTester-Plugin-Diff checkoutnix run . — the DIFF plugin on 127.0.0.1:8095
monkeytester-esp32-sensor, monkeytester-esp32-servertheir plugin checkoutsnix run . — ESP32 device plugins on 127.0.0.1:8091 / 127.0.0.1:8093; the server plugin's fake hub (:8092) stays on the LAN for the real sensor board
monkeytester-websitea worktree of MonkeyTester-Website at origin/masterpython3 -m http.server 8001 --bind 0.0.0.0

The viewer's drop-ins in ~/.config/systemd/user/monkeytester-viewer.service.d/ still carry CONTROLLER_URL, MT_PLUGINS and MT_BUILD_LOCAL_URL from before Settings owned them; the viewer imported each once and now ignores them (Settings → Plugins holds the addresses), so a fresh install needs none. They hold no tokens. The old visualtest-* units are retired: leave them stopped.

Services on the Mac

All are LaunchAgents in ~/Library/LaunchAgents/ (they need the logged-in GUI session for the keychain and USB devices).

LaunchAgentRunsLog
com.blackjackfruit.monkeytester-mobile-controller/usr/bin/python3 device_controller.py with APPIUM_ORG_ID, APPIUM_SIGNING_ID, APPIUM_WDA_BUNDLE_ID, DEVELOPER_DIR, CONTROLLER_TOKEN/tmp/monkeytester-mobile-controller.log
com.blackjackfruit.monkeytester-aibin/monkeytester-ai serve --lan with MTAI_MODEL=qwen2.5vl:7b-q4_K_M, MTAI_PORT=8091, MTAI_TOKEN.runtime/logs/service.log
com.blackjackfruit.monkeytester-build-localbuild-local build plugin: Homebrew python3 build_plugin.py on :8094 with ANDROID_HOME, JAVA_HOME, DEVELOPER_DIR, PLUGIN_TOKEN (code host: the lab's Gitea)/tmp/monkeytester-build-local.log
com.blackjackfruit.monkeytester-build-githubbuild-github build plugin: the same contract on :8095, code host GitHub. Its public repo (MonkeyTester-Plugin-Build-GitHub) has no code yet; set up build-local with a GitHub code host insteadplugin.log in its checkout

Toolchain on the Mac: Homebrew (/opt/homebrew) with node, ffmpeg and Appium 3 (xcuitest driver); the Android SDK at ~/Library/Android/sdk (platform-tools, build-tools, platforms, cmdline-tools); Temurin JDK 21 for Gradle builds.

Viewer configuration

Saved in Run/config.json next to app.py (set through Settings → Plugins, not by hand):

{
  "controller_url": "http://192.168.125.71:8090",
  "visual_plugin": "AI",
  "visual_plugin_url": "http://192.168.125.71:8091",
  "plugins": {
    "DIFF":         "http://127.0.0.1:8095",
    "ESP32-SENSOR": "http://127.0.0.1:8091",
    "ESP32-SERVER": "http://127.0.0.1:8093",
    "build-local":  {"url": "http://192.168.125.71:8094"},
    "build-github": {"url": "http://192.168.125.71:8095"}
  }
}

The AI plugin's provider is Local model with qwen2.5vl:7b-q4_K_M. Projects live in build_config.json (mode 0600, git-ignored); the code host's read-only token lives only in the build plugin's own config, never in the viewer. Viewer accounts live in auth_config.json; the tokens the viewer sends to the controller and the plugins, and the CI token, live in service_tokens.json next to it (mode 0600, plaintext) — entered in Settings, never shown again. See Security.

What healthy looks like

Sign in to the viewer and open http://192.168.125.70:8089/api/status (every viewer API requires a login after the security update):

{
  "ok": true,
  "controller": {"ok": true, "url": "http://192.168.125.71:8090", "api_version": 2, "appium": true, "adb": true},
  "vision":     {"ok": true, "plugin": "AI", "api_version": 3, "provider": "local", "model": "qwen2.5vl:7b-q4_K_M"},
  "plugins": {
    "AI":           {"ok": true, "url": "http://192.168.125.71:8091", "contract_version": 1},
    "DIFF":         {"ok": true, "url": "http://127.0.0.1:8095", "contract_version": 1},
    "ESP32-SENSOR": {"ok": true, "url": "http://127.0.0.1:8091", "contract_version": 1},
    "ESP32-SERVER": {"ok": true, "url": "http://127.0.0.1:8093", "contract_version": 1}
  }
}

And the controller lists every connected phone:

curl -s -H "X-Controller-Token: $CONTROLLER_TOKEN" http://192.168.125.71:8090/devices    # iPhone + Android phone

The app under test

The main project tested here is TemperatureSensor-App (Kotlin Multiplatform, Android + iOS). Its mt-tests/ folder holds the cases (onboarding, device-setup) and a SETUP.txt that sets their order. The lab's build plugin on the Mac builds both apps from the .monkeytester/build-android.sh and .monkeytester/build-ios.sh committed to the repo, and submits them as one run. See Build & Test.