summaryrefslogtreecommitdiffstats
path: root/remote/modules/pvs2/data
diff options
context:
space:
mode:
authorJonathan Bauer2016-05-19 18:13:38 +0200
committerJonathan Bauer2016-05-19 18:13:38 +0200
commit81b256bf9f6ac208b37ec4fb2a0b854700750fe2 (patch)
tree33b974ecd80b8a3ac4d2896ebbf027fd0859b36f /remote/modules/pvs2/data
parent[kernel-vanilla] -> 4.4.10 (diff)
downloadtm-scripts-81b256bf9f6ac208b37ec4fb2a0b854700750fe2.tar.gz
tm-scripts-81b256bf9f6ac208b37ec4fb2a0b854700750fe2.tar.xz
tm-scripts-81b256bf9f6ac208b37ec4fb2a0b854700750fe2.zip
[pvs2] startup scripts for pvsclient & support for external scripts called by pvs2
Diffstat (limited to 'remote/modules/pvs2/data')
-rwxr-xr-xremote/modules/pvs2/data/opt/openslx/bin/pvsstartup15
-rwxr-xr-xremote/modules/pvs2/data/opt/openslx/scripts/setup-pvsmgr2
-rwxr-xr-xremote/modules/pvs2/data/opt/openslx/vmchooser/sessionstart.d/50-PVSclient4
3 files changed, 18 insertions, 3 deletions
diff --git a/remote/modules/pvs2/data/opt/openslx/bin/pvsstartup b/remote/modules/pvs2/data/opt/openslx/bin/pvsstartup
new file mode 100755
index 00000000..def24a81
--- /dev/null
+++ b/remote/modules/pvs2/data/opt/openslx/bin/pvsstartup
@@ -0,0 +1,15 @@
+#!/bin/ash
+
+# TODO UNTESTED!
+timediff=5
+while [ $timediff -gt 3 ]; do
+ start="$(date +%s)"
+ pvsclient $@
+ ret=$?
+ end="$(date +%s)"
+ /opt/openslx/pvs2/unlock.sh
+ [ "$ret" == "0" ] && break
+ timediff=$(( end - start ))
+done
+
+
diff --git a/remote/modules/pvs2/data/opt/openslx/scripts/setup-pvsmgr b/remote/modules/pvs2/data/opt/openslx/scripts/setup-pvsmgr
index dedb0995..7a6c13d9 100755
--- a/remote/modules/pvs2/data/opt/openslx/scripts/setup-pvsmgr
+++ b/remote/modules/pvs2/data/opt/openslx/scripts/setup-pvsmgr
@@ -1,4 +1,4 @@
#!/bin/ash
openbox &
-exec /opt/openslx/bin/pvsmgr
+exec /opt/openslx/bin/pvsmgr --manager-only
diff --git a/remote/modules/pvs2/data/opt/openslx/vmchooser/sessionstart.d/50-PVSclient b/remote/modules/pvs2/data/opt/openslx/vmchooser/sessionstart.d/50-PVSclient
index 0ad739e0..86f26a17 100755
--- a/remote/modules/pvs2/data/opt/openslx/vmchooser/sessionstart.d/50-PVSclient
+++ b/remote/modules/pvs2/data/opt/openslx/vmchooser/sessionstart.d/50-PVSclient
@@ -19,8 +19,8 @@ if [ -n "${PVSMGR_SESSION_CMD}" ]; then
fi
# If the ENV var PVS has been set by vmchooser start pvsclient
if [ -n "$PVS_AUTO_CONNECT" -a "$PVS_AUTO_CONNECT" == "TRUE" ]; then
- pvsclient --auto &
+ pvsstartup --auto &
else
- pvsclient &
+ pvsstartup &
fi
exit 0