From 28ba382f11ec527f884781b40ab4d67ad7192524 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Thu, 18 Apr 2013 15:26:52 +0000 Subject: [PATCH] warn if reload is run as non root user --- reload.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/reload.sh b/reload.sh index 7db803f8..5f3017b2 100755 --- a/reload.sh +++ b/reload.sh @@ -1,4 +1,8 @@ #!/bin/sh +if [ `whoami` != 'root' ]; then + echo you have to be root or run with sudo + exit 1 +fi for service in pandora pandora-tasks pandora-encoding pandora-cron; do service $service reload done