@@ -32,72 +32,13 @@ install -d -o appuser -g appuser -m 0700 "$state_dir"
3232install -d -o root -g root -m 0555 "$unit_dir"
3333install -d -o root -g root -m 0755 "$shim_dir"
3434install -o root -g root -m 0755 scripts/e2e/lib/doctor-install-switch/shims/systemctl "$shim_dir/systemctl"
35- install -o root -g root -m 0755 /dev/stdin "$shim_dir/busctl" <<'BUSCTL'
36- #!/usr/bin/env bash
37- set -euo pipefail
38-
39- manager=org.freedesktop.systemd1
40- object_path=/org/freedesktop/systemd1/unit/openclaw_2dgateway_2eservice
41- actual=("$@")
42- expected=(--user --json=short)
43-
44- reject_invocation() {
45- printf '%s\n' 'Unsupported sealed systemd busctl invocation.' >&2
46- exit 1
47- }
48-
49- case "${actual[2]:-}" in
50- call)
51- expected+=(call "$manager" /org/freedesktop/systemd1 "$manager.Manager" LoadUnit s openclaw-gateway.service)
52- response=manager
53- ;;
54- get-property)
55- case "${actual[5]:-}" in
56- "$manager.Service")
57- expected+=(get-property "$manager" "$object_path" "$manager.Service" ExecStart WorkingDirectory Environment EnvironmentFiles UnsetEnvironment)
58- response=service
59- ;;
60- "$manager.Unit")
61- expected+=(get-property "$manager" "$object_path" "$manager.Unit" FragmentPath DropInPaths NeedDaemonReload LoadState)
62- response=unit
63- ;;
64- *) reject_invocation ;;
65- esac
66- ;;
67- *) reject_invocation ;;
68- esac
69-
70- [[ "${#actual[@]}" -eq "${#expected[@]}" ]] || reject_invocation
71- for index in "${!expected[@]}"; do
72- [[ "${actual[$index]}" == "${expected[$index]}" ]] || reject_invocation
73- done
74-
75- case "$response" in
76- manager)
77- printf '%s\n' '{"type":"o","data":["/org/freedesktop/systemd1/unit/openclaw_2dgateway_2eservice"]}'
78- ;;
79- service)
80- printf '%s\n' \
81- '{"type":"a(sasbttttuii)","data":[["/usr/local/bin/node",["/usr/local/bin/node","/app/openclaw.mjs","gateway","--port","18789"],false,0,0,0,0,0,0,0]]}' \
82- '{"type":"s","data":"/app"}' \
83- '{"type":"as","data":["OPENCLAW_GATEWAY_PORT=18789"]}' \
84- '{"type":"a(sb)","data":[["/home/appuser/.openclaw/gateway.systemd.env",false]]}' \
85- '{"type":"as","data":[]}'
86- ;;
87- unit)
88- printf '%s\n' \
89- '{"type":"s","data":"/home/appuser/.config/systemd/user/openclaw-gateway.service"}' \
90- '{"type":"as","data":[]}' \
91- '{"type":"b","data":false}' \
92- '{"type":"s","data":"loaded"}'
93- ;;
94- esac
95- BUSCTL
35+ install -o root -g root -m 0755 scripts/e2e/lib/doctor-install-switch/shims/busctl "$shim_dir/busctl"
36+ install -o root -g root -m 0644 scripts/e2e/lib/doctor-install-switch/shims/systemd-exec-start.mjs "$shim_dir/systemd-exec-start.mjs"
9637
9738install_sealed_unit() {
9839 install -o root -g "$1" -m "$2" /dev/stdin "$unit_path" <<'UNIT'
9940[Unit]
100- Description=OpenClaw Gateway (sealed ownership proof)
41+ Description=OpenClaw Gateway (umbreon-latest sealed ownership proof)
10142[Service]
10243ExecStart=/usr/local/bin/node /app/openclaw.mjs gateway --port 18789
10344WorkingDirectory=/app
0 commit comments