1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/limesurvey_ynh.git synced 2024-09-03 19:36:32 +02:00

Fix install after remove

This commit is contained in:
Félix Piédallu 2024-01-23 18:49:28 +01:00
parent dbfc1553d3
commit 0f5bf89c44
2 changed files with 7 additions and 1 deletions

View file

@ -68,6 +68,7 @@ ram.runtime = "50M"
sha256 = "4c0a96d610c6740ff7467cf1916a923949bf4c00e99a3cd33509335f884e138b" sha256 = "4c0a96d610c6740ff7467cf1916a923949bf4c00e99a3cd33509335f884e138b"
autoupdate.strategy = "latest_github_commit" autoupdate.strategy = "latest_github_commit"
autoupdate.upstream = "https://github.com/zamentur/libreform" autoupdate.upstream = "https://github.com/zamentur/libreform"
prefetch = false
[resources.system_user] [resources.system_user]

View file

@ -26,7 +26,12 @@ ynh_script_progression --message="Setting up source files..." --weight=1
ynh_setup_source --dest_dir="$install_dir" ynh_setup_source --dest_dir="$install_dir"
# Move upload directory to data_dir, with a symlink # Move upload directory to data_dir, with a symlink
mv "$install_dir/upload" "$data_dir" if [ -d "$data_dir/upload" ]; then
ynh_warn "An upload directory already exist, reusing it."
else
mv "$install_dir/upload" "$data_dir"
fi
ln -s "$data_dir/upload" "$install_dir/upload" ln -s "$data_dir/upload" "$install_dir/upload"
chmod 750 "$install_dir" chmod 750 "$install_dir"