Fix LUSER creation (or no creation).
This commit is contained in:
parent
7b7b5e9624
commit
dd7e0f6793
1 changed files with 7 additions and 4 deletions
|
@ -528,8 +528,8 @@ ck_UID:
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mk_SETUP:
|
mk_SETUP:
|
||||||
@sudo make save-luser
|
|
||||||
@\$(call echo_SU_request)
|
@\$(call echo_SU_request)
|
||||||
|
@sudo make save-luser
|
||||||
@sudo make BREAKPOINT=\$(BREAKPOINT) SETUP
|
@sudo make BREAKPOINT=\$(BREAKPOINT) SETUP
|
||||||
@touch \$@
|
@touch \$@
|
||||||
|
|
||||||
|
@ -628,15 +628,18 @@ create-sbu_du-report: mk_BOOT
|
||||||
save-luser:
|
save-luser:
|
||||||
@\$(call echo_message, Building)
|
@\$(call echo_message, Building)
|
||||||
@LUSER_ID=\$(grep '^\$(LUSER):' /etc/passwd | cut -d: -f3); \\
|
@LUSER_ID=\$(grep '^\$(LUSER):' /etc/passwd | cut -d: -f3); \\
|
||||||
if [ -n "\$LUSER_ID" ]; then \\
|
if [ -n "\$\$LUSER_ID" ]; then \\
|
||||||
if [ ! -d \$(LUSER_HOME).XXX ]; then \\
|
if [ ! -d \$(LUSER_HOME).XXX ]; then \\
|
||||||
mv \$(LUSER_HOME){,.XXX}; \\
|
mv \$(LUSER_HOME){,.XXX}; \\
|
||||||
mkdir \$(LUSER_HOME); \\
|
mkdir \$(LUSER_HOME); \\
|
||||||
chown \$(LUSER):\$(LGROUP) \$(LUSER_HOME); \\
|
chown \$(LUSER):\$(LGROUP) \$(LUSER_HOME); \\
|
||||||
echo "\$LUSER_ID" > luser-id; \\
|
|
||||||
fi; \\
|
fi; \\
|
||||||
|
echo "\$\$LUSER_ID" > luser-id; \\
|
||||||
|
echo User \$(LUSER) exists with ID \$\$LUSER_ID; \\
|
||||||
else \\
|
else \\
|
||||||
rm luser-id; \\
|
rm luser-id; \\
|
||||||
|
echo User \$(LUSER) does not exist; \\
|
||||||
|
echo It will be created with book instructions.; \\
|
||||||
fi
|
fi
|
||||||
@\$(call housekeeping)
|
@\$(call housekeeping)
|
||||||
|
|
||||||
|
|
Reference in a new issue