summaryrefslogtreecommitdiffstats
path: root/system-config/components/1130-login
diff options
context:
space:
mode:
Diffstat (limited to 'system-config/components/1130-login')
-rwxr-xr-xsystem-config/components/1130-login35
1 files changed, 35 insertions, 0 deletions
diff --git a/system-config/components/1130-login b/system-config/components/1130-login
new file mode 100755
index 0000000..616f473
--- /dev/null
+++ b/system-config/components/1130-login
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+## live-config(7) - System Configuration Components
+## Copyright (C) 2006-2015 Daniel Baumann <mail@daniel-baumann.ch>
+##
+## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
+## This is free software, and you are welcome to redistribute it
+## under certain conditions; see COPYING for details.
+
+
+#set -e
+
+Init ()
+{
+ # Checking if package is installed
+ if [ ! -e /var/lib/dpkg/info/login.list ] || \
+ [ -e /var/lib/live/config/login ]
+ then
+ exit 0
+ fi
+
+ echo -n " login"
+}
+
+Config ()
+{
+ # lastlog with autologin doesn't make sense
+ sed -i '/^[^#].*pam_lastlog\.so/s/^/# /' /etc/pam.d/login
+
+ # Creating state file
+ touch /var/lib/live/config/login
+}
+
+Init
+Config