melawy-skel-root/root/.local/bin/tor.sh

16 lines
213 B
Bash
Raw Normal View History

2025-01-16 13:22:53 +05:00
#!/bin/bash
if [[ "$UID" != 0 ]]; then
echo "USER NOT ROOT"
sudo "$0"
exit
else
echo "USER IS ROOT"
fi
$status=$(systemctl status tor)
if [[ "$status" != 0 ]]; then
systemctl restart tor
fi