Change nextcloud password

This commit is contained in:
Bob Mottram 2017-05-09 12:03:49 +01:00
parent fd175a988c
commit a3025cc142
1 changed files with 8 additions and 0 deletions

View File

@ -65,6 +65,14 @@ function add_user_nextcloud {
echo '0' echo '0'
} }
function change_password_nextcloud {
curr_username="$1"
export OC_PASS="$2"
su -s /bin/sh www-data -c "php occ user:resetpassword --password-from-env $curr_username"
export OC_PASS=""
}
function install_interactive_nextcloud { function install_interactive_nextcloud {
if [ ! $ONION_ONLY ]; then if [ ! $ONION_ONLY ]; then
ONION_ONLY='no' ONION_ONLY='no'