mirror of
https://github.com/YunoHost-Apps/pgadmin_ynh.git
synced 2024-09-03 19:56:38 +02:00
Fix issues on upgrade of major debian version
This commit is contained in:
parent
42f2e29611
commit
fedc22a80b
2 changed files with 11 additions and 0 deletions
|
@ -26,6 +26,13 @@ setup_dir() {
|
|||
}
|
||||
|
||||
install_source() {
|
||||
# Clean venv is it was on python with an old version in case major upgrade of debian
|
||||
if [ ! -e $final_path/lib/python$python_version ]; then
|
||||
ynh_secure_remove --file=$final_path
|
||||
fi
|
||||
|
||||
mkdir -p $final_path
|
||||
|
||||
if [ -n "$(uname -m | grep arm)" ]
|
||||
then
|
||||
# Clean old file, sometime it could make some big issues if we don't do this !!
|
||||
|
|
|
@ -40,6 +40,10 @@ ynh_system_user_create --username $pgadmin_user --home_dir /var/lib/$app
|
|||
ynh_script_progression --message="Restoring files..." --weight=5
|
||||
ynh_restore
|
||||
|
||||
# Check that the good python version is installed
|
||||
# If not upgrade the source
|
||||
install_sources
|
||||
|
||||
# POPULATE THE DATABASE
|
||||
ynh_script_progression --message="Reconfiguring Postgresql database..."
|
||||
ynh_psql_test_if_first_run
|
||||
|
|
Loading…
Reference in a new issue