projects
/
grml-autoconfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Run grml-x with specified window-manager. Thanks to Wolfgang Scheicher for
[grml-autoconfig.git]
/
autoconfig.functions
diff --git
a/autoconfig.functions
b/autoconfig.functions
index
b890f4c
..
70bb125
100755
(executable)
--- a/
autoconfig.functions
+++ b/
autoconfig.functions
@@
-1053,7
+1053,7
@@
if checkbootparam 'ssh' ; then
SSH_PASSWD=''
SSH_PASSWD="$(getbootparam 'ssh' 2>>$DEBUG)"
config_userlocal
SSH_PASSWD=''
SSH_PASSWD="$(getbootparam 'ssh' 2>>$DEBUG)"
config_userlocal
- einfo "Bootoption ssh found, trying to set password for user $localuser"
+ einfo "Bootoption ssh found, trying to set password for
root and
user $localuser"
[ -z "$localuser" ] && eend 1
eindent
if [ -z "$SSH_PASSWD" ] ; then
[ -z "$localuser" ] && eend 1
eindent
if [ -z "$SSH_PASSWD" ] ; then
@@
-1082,20
+1082,21
@@
if checkbootparam 'ssh' ; then
# finally check if we have a password we can use:
if [ -n "$SSH_PASSWD" ] ; then
# chpasswd sucks, seriously.
# finally check if we have a password we can use:
if [ -n "$SSH_PASSWD" ] ; then
# chpasswd sucks, seriously.
+ chpass_options=""
if chpasswd --help 2>&1 | grep -q -- '-m,' ; then
if chpasswd --help 2>&1 | grep -q -- '-m,' ; then
- echo "$localuser:$SSH_PASSWD" | chpasswd -m
- else
- echo "$localuser:$SSH_PASSWD" | chpasswd
+ chpass_options="-m"
fi
fi
+ echo "$localuser:$SSH_PASSWD" | chpasswd $chpass_options
+ echo "root:$SSH_PASSWD" | chpasswd $chpass_options
fi
fi
- einfo "Starting secure shell server in background for user $localuser"
+ einfo "Starting secure shell server in background for
root and
user $localuser"
/etc/init.d/rmnologin start >>$DEBUG 2>>$DEBUG
/etc/init.d/ssh start >>$DEBUG 2>>$DEBUG &
eend $?
eindent
/etc/init.d/rmnologin start >>$DEBUG 2>>$DEBUG
/etc/init.d/ssh start >>$DEBUG 2>>$DEBUG &
eend $?
eindent
- ewarn "Warning: please change the password for user $localuser as soon as possible!"
+ ewarn "Warning: please change the password for
root and
user $localuser as soon as possible!"
eoutdent
fi
}
eoutdent
fi
}
@@
-1475,7
+1476,7
@@
if checkbootparam 'startx' && ! echo "$CMDLINE" | grep -q 'startx.*nostartx' ; t
config_userlocal
cat>|/etc/init.d/xstartup<<EOF
#!/bin/sh
config_userlocal
cat>|/etc/init.d/xstartup<<EOF
#!/bin/sh
-su $localuser -c "/usr/bin/grml-x"
+su $localuser -c "/usr/bin/grml-x
${WINDOWMANAGER}
"
EOF
chmod 755 /etc/init.d/xstartup
EOF
chmod 755 /etc/init.d/xstartup