mirror of
https://github.com/YunoHost-Apps/seafile_ynh.git
synced 2024-09-03 20:26:01 +02:00
Fix somes issues on upgrades
This commit is contained in:
parent
21f043d846
commit
3b4b63474d
1 changed files with 13 additions and 12 deletions
|
@ -128,33 +128,33 @@ case $installed_version in
|
||||||
"4.1."* )
|
"4.1."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_4.2.1.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_4.2.1.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"4.3."* )
|
"4.3."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_4.4.3.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_4.4.3.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"4.4."* )
|
"4.4."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_5.0.3.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_5.0.3.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"5.0."* )
|
"5.0."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_5.1.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_5.1.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"5.1."* )
|
"5.1."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_6.0.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_6.0.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"6.0."* )
|
"6.0."* )
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
|
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
expect_scripts/upgrade_6.1.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_6.1.exp $final_path/seafile-server-7.0.5
|
||||||
|
|
||||||
# Enable manually wiki
|
# Enable manually wiki
|
||||||
echo 'ENABLE_WIKI = True' | tee -a $final_path/conf/seahub_settings.py
|
echo 'ENABLE_WIKI = True' | tee -a $final_path/conf/seahub_settings.py
|
||||||
|
@ -162,12 +162,12 @@ case $installed_version in
|
||||||
"6.1."* )
|
"6.1."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_6.2.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_6.2.exp $final_path/seafile-server-7.0.5
|
||||||
;&
|
;&
|
||||||
"6.2."* )
|
"6.2."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_6.3.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_6.3.exp $final_path/seafile-server-7.0.5
|
||||||
|
|
||||||
# Update logrotate to have the last version
|
# Update logrotate to have the last version
|
||||||
ynh_use_logrotate --logfile $final_path/logs --nonappend
|
ynh_use_logrotate --logfile $final_path/logs --nonappend
|
||||||
|
@ -175,7 +175,7 @@ case $installed_version in
|
||||||
"6.3."* )
|
"6.3."* )
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
install_source_7_0
|
install_source_7_0
|
||||||
expect_scripts/upgrade_7.0.exp $final_path/seafile-server-$seafile_version
|
expect_scripts/upgrade_7.0.exp $final_path/seafile-server-7.0.5
|
||||||
# SSO authentication
|
# SSO authentication
|
||||||
echo 'ENABLE_REMOTE_USER_AUTHENTICATION = True' | tee -a $final_path/conf/seahub_settings.py
|
echo 'ENABLE_REMOTE_USER_AUTHENTICATION = True' | tee -a $final_path/conf/seahub_settings.py
|
||||||
echo "REMOTE_USER_HEADER = 'HTTP_EMAIL'" | tee -a $final_path/conf/seahub_settings.py
|
echo "REMOTE_USER_HEADER = 'HTTP_EMAIL'" | tee -a $final_path/conf/seahub_settings.py
|
||||||
|
@ -203,7 +203,7 @@ CACHES = {
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
# Update seafile by script
|
# Update seafile by script
|
||||||
expect_scripts/upgrade_7.1.exp $final_path/seafile-server-$seafile_version
|
sudo -u $seafile_user expect_scripts/upgrade_7.1.exp $final_path/seafile-server-$seafile_version
|
||||||
|
|
||||||
# Fix seafile data link. Look like that the upgrade script of seafile don't always work correctly
|
# Fix seafile data link. Look like that the upgrade script of seafile don't always work correctly
|
||||||
if [ -e $final_path/seafile-data ]; then
|
if [ -e $final_path/seafile-data ]; then
|
||||||
|
@ -213,11 +213,12 @@ EOF
|
||||||
ln -s $seafile_data $final_path/seafile-data
|
ln -s $seafile_data $final_path/seafile-data
|
||||||
;&
|
;&
|
||||||
"7.1."* )
|
"7.1."* )
|
||||||
expect_scripts/upgrade_8.0.exp $final_path/seafile-server-$seafile_version
|
sudo -u $seafile_user expect_scripts/upgrade_8.0.exp $final_path/seafile-server-$seafile_version
|
||||||
|
echo "FILTER = permission=cn=$app.main,ou=permission,dc=yunohost,dc=org" | tee -a $final_path/conf/ccnet.conf
|
||||||
;&
|
;&
|
||||||
esac
|
esac
|
||||||
|
|
||||||
expect_scripts/minor-upgrade.exp $final_path/seafile-server-$seafile_version
|
sudo -u $seafile_user expect_scripts/minor-upgrade.exp $final_path/seafile-server-$seafile_version
|
||||||
|
|
||||||
## Install webdav and logrotate if not installed
|
## Install webdav and logrotate if not installed
|
||||||
if [[ $installed_version = "4.0."* ]] || [[ $installed_version = "4.1."* ]]
|
if [[ $installed_version = "4.0."* ]] || [[ $installed_version = "4.1."* ]]
|
||||||
|
|
Loading…
Reference in a new issue