summaryrefslogtreecommitdiffstats
path: root/core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars
diff options
context:
space:
mode:
authorSimon Rettberg2021-02-22 11:17:02 +0100
committerSimon Rettberg2021-02-22 11:17:02 +0100
commit9271853d114fea88e86522b217531cef30f86b75 (patch)
treef025c682d64a27555b24824b6c0aa681a3c35b64 /core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars
parent[remote-access] Higher prio for firewall rules (diff)
downloadmltk-9271853d114fea88e86522b217531cef30f86b75.tar.gz
mltk-9271853d114fea88e86522b217531cef30f86b75.tar.xz
mltk-9271853d114fea88e86522b217531cef30f86b75.zip
[apply-slx-vars] New module
Generic module that should evaluate different SLX_* variables from /opt/openslx/config and act upon them.
Diffstat (limited to 'core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars')
-rwxr-xr-xcore/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars15
1 files changed, 15 insertions, 0 deletions
diff --git a/core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars b/core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars
new file mode 100755
index 00000000..22996a38
--- /dev/null
+++ b/core/modules/apply-slx-vars/data/opt/openslx/scripts/apply-slx-vars
@@ -0,0 +1,15 @@
+#!/bin/ash
+
+. /opt/openslx/config
+
+# Disable TTY switch
+if [ "$SLX_TTY_SWITCH" = "no" ]; then
+ mkdir -p /etc/X11/xorg.conf.d
+ cat > /etc/X11/xorg.conf.d/50-no-tty.conf <<EOF
+Section "ServerFlags"
+ Option "DontVTSwitch" "true"
+EndSection
+EOF
+fi
+
+exit 0