Merge pull request #14 from julienmalik/patch-3
[fix] searx breaks /var/cache directory
This commit is contained in:
commit
f03a6c556f
|
@ -20,12 +20,13 @@ sudo apt-get install git build-essential libxslt-dev python-dev python-virtualen
|
|||
# Check Swap
|
||||
if [ $(sudo swapon -s | wc -l) = 1 ];
|
||||
then
|
||||
# It is NOT possible to setup a swap file on a tmpfs filesystem
|
||||
mount | grep /tmp | grep tmpfs > /dev/null 2>&1
|
||||
if [ $? = 1 ];
|
||||
then
|
||||
tmp_swap_file=/tmp/searx_swapfile
|
||||
else
|
||||
tmp_swap_file=/var/cache/
|
||||
tmp_swap_file=/var/cache/searx_swapfile
|
||||
fi
|
||||
sudo dd if=/dev/zero of=$tmp_swap_file bs=1M count=256
|
||||
sudo chmod 600 $tmp_swap_file
|
||||
|
|
Loading…
Reference in New Issue