Print an error if /etc/init.d/i2p is run as non-root so Ubuntu users aren't asked for a non-existing root password
This commit is contained in:
5
debian/scripts/init
vendored
5
debian/scripts/init
vendored
@ -17,6 +17,11 @@ I2P () {
|
|||||||
su i2psvc -c "/usr/lib/i2p/i2prouter $1"
|
su i2psvc -c "/usr/lib/i2p/i2prouter $1"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if [ `id -un` != "root" ]; then
|
||||||
|
echo "This script ($0) must be run as root"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
start)
|
start)
|
||||||
log_daemon_msg "Starting I2P" "i2p"
|
log_daemon_msg "Starting I2P" "i2p"
|
||||||
|
Reference in New Issue
Block a user