change sudo to work stack-panel way
This commit is contained in:
parent
cd39bfc95b
commit
fa6719db54
|
@ -8,8 +8,8 @@
|
||||||
# powerdns-tools include file, used by other powerdns-tools bash scripts
|
# powerdns-tools include file, used by other powerdns-tools bash scripts
|
||||||
|
|
||||||
# Must be root, attempt sudo if need be. root is not actually required for the API commands, but we want to restrict access.
|
# Must be root, attempt sudo if need be. root is not actually required for the API commands, but we want to restrict access.
|
||||||
if [ "${EUID}" -ne 0 ]; then
|
if [ "$USER" != "root" ]; then
|
||||||
exec sudo -u root --shell /bin/bash $0 $@
|
exec sudo -u root $0 $@
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Load local config
|
# Load local config
|
||||||
|
|
Loading…
Reference in New Issue
Block a user