[fix] Handle install on sub folder.

This commit is contained in:
opi 2014-07-21 23:42:32 +02:00
parent 44245ac16d
commit 21b5b056d5
1 changed files with 6 additions and 1 deletions

View File

@ -44,7 +44,12 @@ fi
#Configuration Searx #Configuration Searx
sudo cp ../conf/settings.yml /opt/searx/searx/ sudo cp ../conf/settings.yml /opt/searx/searx/
sudo sed -i -e "s/ultrasecretkey/`openssl rand -hex 16`/g" /opt/searx/searx/settings.yml sudo sed -i -e "s/ultrasecretkey/`openssl rand -hex 16`/g" /opt/searx/searx/settings.yml
sudo sed -i -e "s@ynhbaseurl@https://$domain$path@g" /opt/searx/searx/settings.yml if [ "$path" != "/" ];
then
sudo sed -i -e "s@ynhbaseurl@https://$domain$path/@g" /opt/searx/searx/settings.yml
else
sudo sed -i -e "s@ynhbaseurl@https://$domain$path@g" /opt/searx/searx/settings.yml
fi
# Set permissions to searx directory # Set permissions to searx directory
sudo useradd searx -d /opt/searx sudo useradd searx -d /opt/searx