mirror of
https://github.com/YunoHost-Apps/seafile_ynh.git
synced 2024-09-03 20:26:01 +02:00
Fix seafile-data link management
This commit is contained in:
parent
c94e9d1f1a
commit
471971419b
1 changed files with 5 additions and 4 deletions
|
@ -65,8 +65,9 @@ if [ -z ${seahub_secret_key:-} ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Update data dir if needed
|
# Update data dir if needed
|
||||||
if [ $(readlink $install_dir/seafile-data) == '/home/yunohost.app/seafile-data' ]; then
|
if [ ! -L /home/yunohost.app/seafile-data ] || \
|
||||||
rm $install_dir/seafile-data
|
[ $(readlink $install_dir/seafile-data) = '/home/yunohost.app/seafile-data' ]; then
|
||||||
|
mv $install_dir/seafile-data $install_dir/seafile-data$(date '+%Y%m%d.%H%M%S')
|
||||||
ln -s $data_dir $install_dir/seafile-data
|
ln -s $data_dir $install_dir/seafile-data
|
||||||
fi
|
fi
|
||||||
if [ -e /home/yunohost.app/seafile-data ]; then
|
if [ -e /home/yunohost.app/seafile-data ]; then
|
||||||
|
@ -117,10 +118,10 @@ case $installed_version in
|
||||||
|
|
||||||
# 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 $install_dir/seafile-data ]; then
|
if [ -e $install_dir/seafile-data ]; then
|
||||||
old_data_dir_path="$install_dir/seafile_data$(date '+%Y%m%d.%H%M%S')"
|
old_data_dir_path="$install_dir/seafile-data$(date '+%Y%m%d.%H%M%S')"
|
||||||
mv "$install_dir/seafile-data" "$old_data_dir_path"
|
mv "$install_dir/seafile-data" "$old_data_dir_path"
|
||||||
fi
|
fi
|
||||||
ln -s $seafile_data $install_dir/seafile-data
|
ln -s $data_dir $install_dir/seafile-data
|
||||||
;&
|
;&
|
||||||
"7.1."* )
|
"7.1."* )
|
||||||
sudo -u $YNH_APP_ID $expect_scripts_dir/upgrade_8.0.exp $install_dir/seafile-server-$seafile_version
|
sudo -u $YNH_APP_ID $expect_scripts_dir/upgrade_8.0.exp $install_dir/seafile-server-$seafile_version
|
||||||
|
|
Loading…
Reference in a new issue