only show MOTD once on ssh login

This commit is contained in:
Tobias Powalowski 2023-07-29 08:36:17 +02:00
parent 01e87254e8
commit 05b48f5f97

View file

@ -4,7 +4,7 @@
# simulate login from tty on first screen session
if ! screen -ls &>/dev/null; then
cat /etc/motd
[[ -z "${SSH_TTY}" ]] && cat /etc/motd
echo -e "Hit \e[1m\e[92mENTER\e[m for \e[1mshell\e[m login."
read -r
fi