Comments
This commit is contained in:
parent
25f49664f7
commit
40281de73e
|
@ -61,6 +61,7 @@ function searx_set_default_background {
|
|||
fi
|
||||
fi
|
||||
|
||||
# remove the github ribbon icon
|
||||
if [ -f /etc/searx/searx/static/themes/courgette/img/github_ribbon.png ]; then
|
||||
mv /etc/searx/searx/static/themes/courgette/img/github_ribbon.png /etc/searx/searx/static/themes/courgette/img/github_ribbon.png.old
|
||||
fi
|
||||
|
@ -729,20 +730,31 @@ function create_searx_config {
|
|||
function upgrade_searx {
|
||||
settings_file=${SEARX_PATH}/searx/searx/settings.yml
|
||||
background_image=/etc/searx/searx/static/themes/courgette/img/bg-body-index.jpg
|
||||
|
||||
# save the background image
|
||||
if [ -f ${background_image} ]; then
|
||||
cp ${background_image} ${background_image}.prev
|
||||
fi
|
||||
|
||||
# save the settings
|
||||
cp ${settings_file} ${settings_file}.prev
|
||||
|
||||
# do the upgrade
|
||||
set_repo_commit $SEARX_PATH/searx "searx commit" "$SEARX_COMMIT" $SEARX_REPO
|
||||
|
||||
# restore the background image
|
||||
if [ -f ${background_image}.prev ]; then
|
||||
cp ${background_image}.prev ${background_image}
|
||||
chown -R searx:searx ${SEARX_PATH}/searx
|
||||
fi
|
||||
|
||||
# restore the settings
|
||||
if [ -f ${settings_file}.prev ]; then
|
||||
cp ${settings_file}.prev ${settings_file}
|
||||
chown -R searx:searx ${SEARX_PATH}/searx
|
||||
fi
|
||||
|
||||
# remove the github ribbon icon
|
||||
if [ -f /etc/searx/searx/static/themes/courgette/img/github_ribbon.png ]; then
|
||||
mv /etc/searx/searx/static/themes/courgette/img/github_ribbon.png /etc/searx/searx/static/themes/courgette/img/github_ribbon.png.old
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue