mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-14 10:37:39 -07:00
ubuntu compatible password change function
This commit is contained in:
parent
9784389766
commit
c1dad6ce08
5 changed files with 22 additions and 16 deletions
|
@ -43,7 +43,8 @@ is_object_value_empty 'web' 'DOMAIN' "$domain" '$FTP_USER'
|
|||
# Adding user
|
||||
/usr/sbin/adduser $ftp_user -g $user -s /sbin/nologin -M \
|
||||
-d "$HOMEDIR/$user/web/$domain" > /dev/null 2>&1
|
||||
echo "$ftp_password" | /usr/bin/passwd "$ftp_user" --stdin &>/dev/null
|
||||
echo "$ftp_user:$ftp_password" | /usr/sbin/chpasswd
|
||||
|
||||
ftp_md5="$(awk -v user=$ftp_user -F : 'user == $1 {print $2}' /etc/shadow)"
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue