diff --git a/root/etc/profile.d/shell-timeout.sh b/root/etc/profile.d/shell-timeout.sh new file mode 100644 index 0000000..f90b32f --- /dev/null +++ b/root/etc/profile.d/shell-timeout.sh @@ -0,0 +1,8 @@ +# Set automatic timeout for shell +# which will automatically log out the user after certain amount of time +# This will not work on termunal emulators in X11 +TMOUT="$(( 60*10 ))"; +[ -z "$DISPLAY" ] && export TMOUT; +case $( /usr/bin/tty ) in + /dev/tty[0-9]*) export TMOUT;; +esac