make sure that $1 is a real user
This commit is contained in:
parent
e99df742a1
commit
cfc7064964
@ -15,6 +15,13 @@ for COMMAND in "${COMMANDS_TO_CHECK[@]}"; do
|
||||
fi
|
||||
done
|
||||
|
||||
if [[ -n "$1" ]]; then
|
||||
GUSER="^$1"
|
||||
if ! grep $GUSER /etc/shadow > /dev/null; then
|
||||
>&2 echo "$0: ERROR: unable to find user '$1'"
|
||||
fi
|
||||
fi
|
||||
|
||||
function create_new_image {
|
||||
UBOOT_MAX_SIZE='32'
|
||||
IMAGE_SIZE=$(( $(stat -c '%s' "${IMAGE_NAME}") / 1024 / 1024 ))
|
||||
|
Loading…
Reference in New Issue
Block a user