mirror of
https://github.com/myvesta/vesta
synced 2025-07-06 04:51:54 -07:00
check if user is root in v-update-host-certificate
This commit is contained in:
parent
e48d42617d
commit
62b0d755ad
1 changed files with 3 additions and 4 deletions
|
@ -11,12 +11,11 @@
|
|||
#----------------------------------------------------------#
|
||||
|
||||
whoami=$(whoami)
|
||||
if [ "$whoami" != "root" ] && [ "$whoami" != "admin" ] ; then
|
||||
echo "You must be root or admin to execute this script";
|
||||
exit 1;
|
||||
if [ "$whoami" != "root" ]; then
|
||||
echo "You must be root to execute this script"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
# Argument definition
|
||||
user=$1
|
||||
hostname=$2
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue