mirror of
https://github.com/YunoHost-Apps/ampache_ynh.git
synced 2024-09-03 18:15:55 +02:00
cleaning
This commit is contained in:
parent
c274f72b8f
commit
4c06cd5e5c
2 changed files with 13 additions and 16 deletions
|
@ -87,9 +87,6 @@ ynh_local_curl /update.php?action=update
|
|||
#=================================================
|
||||
ynh_script_progression --message="Loading admin database..." --weight=2
|
||||
|
||||
#cp ../conf/admin.sql /tmp/
|
||||
#ynh_replace_string --match_string="__ADMIN__" --replace_string="$admin" --target_file=/tmp/admin.sql
|
||||
|
||||
ynh_add_config --template="admin.sql" --destination="/tmp/admin.sql"
|
||||
|
||||
ynh_mysql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name < /tmp/admin.sql
|
||||
|
|
|
@ -36,7 +36,7 @@ if [ "$upgrade_type" == "UPGRADE_APP" ]
|
|||
then
|
||||
ynh_script_progression --message="Upgrading source files..." --weight=3
|
||||
|
||||
ynh_setup_source --dest_dir="$install_dir" --keep="config/ampache.cfg.php"
|
||||
ynh_setup_source --dest_dir="$install_dir" #--keep="config/ampache.cfg.php"
|
||||
fi
|
||||
|
||||
chmod -R o-rwx "$install_dir"
|
||||
|
@ -63,20 +63,20 @@ then
|
|||
|
||||
# Install composer
|
||||
ynh_install_composer --workdir=$install_dir
|
||||
ynh_composer_exec --phpversion="${YNH_PHP_VERSION}" --workdir="$install_dir" --commands="config discard-changes true"
|
||||
ynh_composer_exec --workdir="$install_dir" --commands="config discard-changes true"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# UPDATE A CONFIG FILE
|
||||
#=================================================
|
||||
#ynh_script_progression --message="Updating a configuration file..." --weight=1
|
||||
ynh_script_progression --message="Updating a configuration file..." --weight=1
|
||||
|
||||
#(cd $install_dir && ynh_exec_as "$app" php$phpversion bin/cli admin:updateDatabase -e)
|
||||
(cd $install_dir && ynh_exec_as "$app" php$phpversion bin/cli admin:updateDatabase -e)
|
||||
|
||||
#ynh_add_config --template="ampache.cfg.php" --destination="$install_dir/config/ampache.cfg.php"
|
||||
ynh_add_config --template="ampache.cfg.php" --destination="$install_dir/config/ampache.cfg.php"
|
||||
|
||||
#chmod 650 "$install_dir/config/ampache.cfg.php"
|
||||
#chown $app: "$install_dir/config/ampache.cfg.php"
|
||||
chmod 650 "$install_dir/config/ampache.cfg.php"
|
||||
chown $app: "$install_dir/config/ampache.cfg.php"
|
||||
|
||||
#=================================================
|
||||
# UPDATE MULTIMEDIA DIRECTORIES
|
||||
|
@ -89,12 +89,12 @@ ynh_multimedia_build_main_dir
|
|||
# UPGRADE AMPACHE WITH CURL
|
||||
#=================================================
|
||||
|
||||
if [ "$upgrade_type" == "UPGRADE_APP" ]
|
||||
then
|
||||
ynh_local_curl /update.php?action=update
|
||||
sleep 1
|
||||
(cd $install_dir && ynh_exec_as "$app" php$phpversion bin/cli admin:updateDatabase -e)
|
||||
fi
|
||||
#if [ "$upgrade_type" == "UPGRADE_APP" ]
|
||||
#then
|
||||
# ynh_local_curl /update.php?action=update
|
||||
# sleep 1
|
||||
# (cd $install_dir && ynh_exec_as "$app" php$phpversion bin/cli admin:updateDatabase -e)
|
||||
#fi
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
|
|
Loading…
Add table
Reference in a new issue