|
|
@@ -4,6 +4,7 @@ set -euo pipefail
|
|
|
ACTION="$1"
|
|
|
SERIAL_SHORT="$2"
|
|
|
REMOTE_DISPLAY="$(cat "/var/lib/xvfb/$SERIAL_SHORT/display")"
|
|
|
+VNC_PORT="$(cat "/var/lib/xvfb/$SERIAL_SHORT/port")"
|
|
|
|
|
|
for i in {1..10}
|
|
|
do
|
|
|
@@ -14,10 +15,10 @@ done
|
|
|
case "$ACTION"
|
|
|
in
|
|
|
"start")
|
|
|
- /usr/bin/xpra control :"$REMOTE_DISPLAY" start "/usr/local/bin/x11vnc_for_android_start.sh"
|
|
|
+ /usr/bin/xpra control :"$REMOTE_DISPLAY" start "/usr/local/bin/x11vnc_for_android_start.sh" "$VNC_PORT"
|
|
|
;;
|
|
|
"stop")
|
|
|
- /usr/bin/xpra control :"$REMOTE_DISPLAY" start "/usr/local/bin/x11vnc_for_android_stop.sh"
|
|
|
+ /usr/bin/xpra control :"$REMOTE_DISPLAY" start "/usr/local/bin/x11vnc_for_android_stop.sh" "$VNC_PORT"
|
|
|
;;
|
|
|
*)
|
|
|
exit 1
|