diff --git a/samba.sh b/samba.sh index b909b41..d49d459 100755 --- a/samba.sh +++ b/samba.sh @@ -92,7 +92,7 @@ timezone() { local timezone="${1:-EST5EDT}" # Return: user added to container user() { local name="${1}" passwd="${2}" id="${3:-""}" useradd "$name" -M ${id:+-u $id} - echo "$passwd" | tee - | smbpasswd -s -a "$name" + printf "$passwd\n$passwd\n" | tee - | smbpasswd -s -a "$name" } ### workgroup: set the workgroup @@ -171,4 +171,4 @@ elif ps -ef | egrep -v grep | grep -q smbd; then else [[ ${NMBD:-""} ]] && ionice -c 3 nmbd -D exec ionice -c 3 smbd -FS