Fix bugs with arch and debian install scripts
This commit is contained in:
parent
1a155f8668
commit
d11d64cc50
@ -22,9 +22,9 @@ fi
|
|||||||
|
|
||||||
# install basic dependencies
|
# install basic dependencies
|
||||||
|
|
||||||
echo -e "\033[0;32mInstalling apt dependencies...\033[0m"
|
echo -e "\033[0;32mInstalling pacman dependencies...\033[0m"
|
||||||
|
|
||||||
pacman --needed --noconfirm -S git curl python python-pip tor > /dev/null
|
! ((pacman --needed --noconfirm -S git curl python python-pip tor > /dev/null) 2>&1 | grep -v warning 1>&2) | grep .
|
||||||
|
|
||||||
# get the repository
|
# get the repository
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@ fi
|
|||||||
|
|
||||||
echo -e "\033[0;32mInstalling apt dependencies...\033[0m"
|
echo -e "\033[0;32mInstalling apt dependencies...\033[0m"
|
||||||
|
|
||||||
apt install -y git curl python3.7 python3-pip python3-setuptools tor > /dev/null
|
apt-get install -y git curl python3.7 python3-pip python3-setuptools tor > /dev/null
|
||||||
|
|
||||||
# get the repository
|
# get the repository
|
||||||
|
|
||||||
@ -45,7 +45,7 @@ python3.7 -m pip install --no-input -r "$OUTPUT_DIR/requirements.txt" --require-
|
|||||||
|
|
||||||
# create nologin onionr user if not exists
|
# create nologin onionr user if not exists
|
||||||
|
|
||||||
id -u onionr &>/dev/null || useradd -r -s /sbin/nologin onionr
|
id -u onionr &>/dev/null || useradd -r -s /bin/false onionr
|
||||||
|
|
||||||
chmod 755 "$OUTPUT_DIR"
|
chmod 755 "$OUTPUT_DIR"
|
||||||
chown -R onionr:onionr "$OUTPUT_DIR"
|
chown -R onionr:onionr "$OUTPUT_DIR"
|
||||||
|
@ -8,5 +8,5 @@ export OUTPUT_DIR=${OUTPUT_DIR:=/usr/share/onionr}
|
|||||||
export ONIONR_HOME=${ONIONR_HOME:=/etc/onionr}
|
export ONIONR_HOME=${ONIONR_HOME:=/etc/onionr}
|
||||||
export LOG_DIR=${LOG_DIR:=/var/log/onionr}
|
export LOG_DIR=${LOG_DIR:=/var/log/onionr}
|
||||||
|
|
||||||
cd "$OUTPUT_DIR"
|
cd "$OUTPUT_DIR/onionr"
|
||||||
exec su onionr -s /bin/sh -c "./onionr.sh ""$@"""
|
exec su onionr -s /bin/sh -c "python3.7 onionr.py ""$@"""
|
||||||
|
Loading…
Reference in New Issue
Block a user