mirror of
https://github.com/YunoHost-Apps/searx_ynh.git
synced 2024-09-03 20:16:30 +02:00
keep
This commit is contained in:
parent
659a59f04e
commit
5ec3836cf3
2 changed files with 1 additions and 16 deletions
|
@ -101,7 +101,6 @@ pip3 install --requirement $final_path/requirements-ynh.txt --no-cache-dir
|
||||||
ynh_script_progression --message="Configuring Searx..." --weight=2
|
ynh_script_progression --message="Configuring Searx..." --weight=2
|
||||||
|
|
||||||
secret_key=$(ynh_string_random)
|
secret_key=$(ynh_string_random)
|
||||||
|
|
||||||
ynh_add_config --template="../conf/settings.yml" --destination="$final_path/searx/settings.yml"
|
ynh_add_config --template="../conf/settings.yml" --destination="$final_path/searx/settings.yml"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -83,21 +83,8 @@ if [ "$upgrade_type" == "UPGRADE_APP" ]
|
||||||
then
|
then
|
||||||
ynh_script_progression --message="Upgrading source files..." --weight=3
|
ynh_script_progression --message="Upgrading source files..." --weight=3
|
||||||
|
|
||||||
# Create a temporary directory
|
|
||||||
tmpdir="$(mktemp -d)"
|
|
||||||
|
|
||||||
# Backup the config file in the temp dir
|
|
||||||
cp -a "$final_path/searx/settings.yml" "$tmpdir/settings.yml"
|
|
||||||
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
ynh_setup_source --dest_dir="$final_path"
|
ynh_setup_source --dest_dir="$final_path" --keep="$final_path/searx/settings.yml"
|
||||||
|
|
||||||
# Copy the admin saved settings from tmp directory to final path
|
|
||||||
cp -a "$tmpdir/settings.yml" "$final_path/searx/settings.yml"
|
|
||||||
|
|
||||||
# Remove the tmp directory securely
|
|
||||||
ynh_secure_remove --file="$tmpdir"
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -138,7 +125,6 @@ pip3 install --requirement $final_path/requirements-ynh.txt --upgrade
|
||||||
# ynh_script_progression --message="Configuring Searx..." --weight=2
|
# ynh_script_progression --message="Configuring Searx..." --weight=2
|
||||||
|
|
||||||
# secret_key=$(ynh_string_random)
|
# secret_key=$(ynh_string_random)
|
||||||
|
|
||||||
# ynh_add_config --template="../conf/settings.yml" --destination="$final_path/searx/settings.yml"
|
# ynh_add_config --template="../conf/settings.yml" --destination="$final_path/searx/settings.yml"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Reference in a new issue