summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xetc/init.d/commission9
1 files changed, 7 insertions, 2 deletions
diff --git a/etc/init.d/commission b/etc/init.d/commission
index 7b1b7aa..5241176 100755
--- a/etc/init.d/commission
+++ b/etc/init.d/commission
@@ -11,6 +11,8 @@ CONF_DIR=/var/config
ENABLED=yes
PASSWORDS=$(passwd -Sa | egrep '^[^[:space:]]+[[:space:]]P[[:space:]]' | wc -l)
+
+[ -f "/etc/default/rcS" ] && . "/etc/default/rcS"
if (($PASSWORDS == 0)) ; then
# No password, so indicate commissioning mode
# php-fpm-commision will be turned on as well
@@ -33,8 +35,11 @@ fi
case "$1" in
start)
if [ "$ENABLED" != "yes" ]; then
- echo "$NAME: disabled:"
- echo "$PASSWORDS"
+ echo "Some user has a password"
+ if [ "$VERBOSE" = very ] ; then
+ passwd -Sa | egrep '^[^[:space:]]+[[:space:]]P[[:space:]]' | logger -s -p daemon.notice
+ echo "user count with passwords: $PASSWORDS"
+ fi
exit
fi
echo -n "Starting $DESC: "