Onionr/install/onionr

16 lines
319 B
Plaintext
Raw Normal View History

#!/bin/sh
set -e
[ "root" != "$USER" ] && exec sudo $0 "$@"
export OUTPUT_DIR=${OUTPUT_DIR:=/usr/share/onionr}
2019-03-28 19:03:37 +00:00
export ONIONR_HOME=${ONIONR_HOME:=/etc/onionr}
export LOG_DIR=${LOG_DIR:=/var/log/onionr}
cd "$OUTPUT_DIR/onionr"
command="python3.7 onionr.py '$@'"
echo $command
exec su onionr -s /bin/sh -c "$command"