add option to pass action to reload, i.e. restart/stop/start
This commit is contained in:
parent
e7c1813e97
commit
a6b232b702
1 changed files with 6 additions and 1 deletions
|
@ -3,6 +3,11 @@ if [ `whoami` != 'root' ]; then
|
||||||
echo you have to be root or run with sudo
|
echo you have to be root or run with sudo
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
if [ -z "$1" ]; then
|
||||||
|
action=reload
|
||||||
|
else
|
||||||
|
action="$1"
|
||||||
|
fi
|
||||||
for service in pandora pandora-tasks pandora-encoding pandora-cron; do
|
for service in pandora pandora-tasks pandora-encoding pandora-cron; do
|
||||||
service $service reload
|
service $service $action
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in a new issue