diff options
author | Daniil Baturin <daniil@baturin.org> | 2014-07-29 23:21:02 +0200 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2014-07-29 23:21:02 +0200 |
commit | 127b7a12dbfabfe33b8d3733648c1bec1fa5d323 (patch) | |
tree | d49713b7230a20f4cc59cdc38ad75a05a8237c15 /scripts/install/install-image-new | |
parent | 6ef45f7e83ce58b23442abb4887fe2a9eb50d803 (diff) | |
download | vyatta-cfg-system-127b7a12dbfabfe33b8d3733648c1bec1fa5d323.tar.gz vyatta-cfg-system-127b7a12dbfabfe33b8d3733648c1bec1fa5d323.zip |
Replace login name check with effective UID check.
Diffstat (limited to 'scripts/install/install-image-new')
-rwxr-xr-x | scripts/install/install-image-new | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/install/install-image-new b/scripts/install/install-image-new index 5c87c1ea..7965b939 100755 --- a/scripts/install/install-image-new +++ b/scripts/install/install-image-new @@ -1,8 +1,8 @@ #!/bin/bash -if [ `whoami` != 'root' ] ; then - echo "This script must be run with root privileges." - exit 1 +if [ $(id -u) != 0 ]; then + echo "Image installation requires root privileges!" + exit 1 fi # source in the functions |