summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/runit-scripts/runitscripts/services/evrouter/run
diff options
context:
space:
mode:
Diffstat (limited to 'abs/core-testing/runit-scripts/runitscripts/services/evrouter/run')
-rwxr-xr-xabs/core-testing/runit-scripts/runitscripts/services/evrouter/run12
1 files changed, 10 insertions, 2 deletions
diff --git a/abs/core-testing/runit-scripts/runitscripts/services/evrouter/run b/abs/core-testing/runit-scripts/runitscripts/services/evrouter/run
index 1d7389a..5697f6f 100755
--- a/abs/core-testing/runit-scripts/runitscripts/services/evrouter/run
+++ b/abs/core-testing/runit-scripts/runitscripts/services/evrouter/run
@@ -1,5 +1,13 @@
#!/bin/bash
. /etc/profile
-sv start Xvfb
-su mythtv -c "DISPLAY=localhost:50 evrouter -c /etc/evrouter.cfg -f /dev/input/event*"
+which evrouter >/dev/null 2>/dev/null
+if [ $? = 0 ]
+then
+ ps -ef |grep -v grep|grep -q "Xvfb :50"
+ if [ ! $? = 0 ]
+ then
+ sv start Xvfb
+ fi
+ su mythtv -c "DISPLAY=localhost:50 evrouter -c /etc/evrouter.cfg -f /dev/input/event*"
+fi