Browse Source

init.d: sysv adduser_compat check readonly /etc

pull/81/head
bol-van 3 years ago
parent
commit
9df16b8578
  1. 4
      init.d/sysv/functions

4
init.d/sysv/functions

@ -31,6 +31,9 @@ user_exists()
useradd_compat()
{
# $1 - username
# skip for readonly systems
[ -w "/etc" ] && {
if exists useradd ; then
useradd --no-create-home --system --shell /bin/false $1
elif is_linked_to_busybox adduser ; then
@ -39,6 +42,7 @@ useradd_compat()
elif exists adduser; then
adduser --no-create-home --system --disabled-login $1
fi
}
user_exists $1
}
prepare_user()

Loading…
Cancel
Save