summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xcore/modules/idleaction/data/opt/openslx/scripts/idleaction-scheduled_action6
-rwxr-xr-xcore/modules/slxbrowser/data/opt/openslx/scripts/systemd-setup_kiosk4
2 files changed, 9 insertions, 1 deletions
diff --git a/core/modules/idleaction/data/opt/openslx/scripts/idleaction-scheduled_action b/core/modules/idleaction/data/opt/openslx/scripts/idleaction-scheduled_action
index 2717d6cb..df9fd65c 100755
--- a/core/modules/idleaction/data/opt/openslx/scripts/idleaction-scheduled_action
+++ b/core/modules/idleaction/data/opt/openslx/scripts/idleaction-scheduled_action
@@ -77,7 +77,11 @@ runaction () {
sleep $(( DELAY * 60 ))
fi
for MINUTES in 5 X X X X X X X 3 X X X 2 X X X 1 X X X; do
- NUM=$(who | wc -l)
+ if [ -f "/run/openslx/demo-no-logout-delay" ]; then
+ NUM=$(who | grep -v '^demo ' | wc -l)
+ else
+ NUM=$(who | wc -l)
+ fi
[ "$NUM" = "0" ] && break
if [ "$MINUTES" != "X" ]; then
USERS=0
diff --git a/core/modules/slxbrowser/data/opt/openslx/scripts/systemd-setup_kiosk b/core/modules/slxbrowser/data/opt/openslx/scripts/systemd-setup_kiosk
index 6635bc19..b8761aab 100755
--- a/core/modules/slxbrowser/data/opt/openslx/scripts/systemd-setup_kiosk
+++ b/core/modules/slxbrowser/data/opt/openslx/scripts/systemd-setup_kiosk
@@ -3,6 +3,10 @@
# Autologin
sed -i '/^AutoLoginDelay=/d;/^AutoLoginUser=/d;s/^AutoLoginEnable=.*$/AutoLoginEnable=true\nAutoLoginUser=demo\nAutoLoginDelay=0/' "/etc/kde4/kdm/kdmrc"
+# Disable logout delay for demo user on shutdown/reboot/...
+mkdir -p "/run/openslx"
+touch "/run/openslx/demo-no-logout-delay"
+
# desktop session
cat > /opt/openslx/xsessions/default.desktop <<EOF
[Desktop Entry]