mirror of
https://github.com/YunoHost-Apps/my_webapp_ynh.git
synced 2024-09-03 19:46:26 +02:00
Fix password change
This commit is contained in:
parent
0b62011418
commit
cab30de685
1 changed files with 6 additions and 1 deletions
|
@ -59,7 +59,7 @@ get__free_footprint() {
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
set__password() {
|
set__password() {
|
||||||
if [ "$password" == "" ]
|
if [ ! "$password" == "" ]
|
||||||
then
|
then
|
||||||
ynh_app_setting_set --app=$app --key=password --value="$password"
|
ynh_app_setting_set --app=$app --key=password --value="$password"
|
||||||
fi
|
fi
|
||||||
|
@ -148,6 +148,11 @@ ynh_app_config_apply() {
|
||||||
ynh_system_user_del_group --username=$app --groups="sftp.app"
|
ynh_system_user_del_group --username=$app --groups="sftp.app"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "${changed[password]}" == "true" ] && [ ! "$password" == "" ]
|
||||||
|
then
|
||||||
|
chpasswd <<< "${app}:${password}"
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$phpversion" != "none" ]
|
if [ "$phpversion" != "none" ]
|
||||||
then
|
then
|
||||||
ynh_add_fpm_config --phpversion=$phpversion --usage=$fpm_usage --footprint=$fpm_footprint
|
ynh_add_fpm_config --phpversion=$phpversion --usage=$fpm_usage --footprint=$fpm_footprint
|
||||||
|
|
Loading…
Add table
Reference in a new issue