diff options
-rwxr-xr-x | ezjail-admin | 3 | ||||
-rwxr-xr-x | ezjail.sh | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/ezjail-admin b/ezjail-admin index 249f312..881953e 100755 --- a/ezjail-admin +++ b/ezjail-admin | |||
@@ -444,8 +444,9 @@ delete) | |||
444 | ######################## ezjail-admin LIST ######################## | 444 | ######################## ezjail-admin LIST ######################## |
445 | list) | 445 | list) |
446 | [ $# -eq 1 ] || exerr ${ezjail_usage_list} | 446 | [ $# -eq 1 ] || exerr ${ezjail_usage_list} |
447 | unset ezjail_list | ||
447 | 448 | ||
448 | ezjail_list=`find -X ${ezjail_prefix}/etc/ezjail/ 2> /dev/null | xargs rcorder | xargs basename -a` | 449 | [ -d ${ezjail_prefix}/etc/ezjail/ ] && cd ${ezjail_prefix}/etc/ezjail/ && ezjail_list=`ls | xargs rcorder` |
449 | 450 | ||
450 | printf "%-3s %-5s %-15s %-28s %s\\n" STA JID IP Hostname "Root Directory" | 451 | printf "%-3s %-5s %-15s %-28s %s\\n" STA JID IP Hostname "Root Directory" |
451 | echo "--- ----- --------------- ---------------------------- -------------------------" | 452 | echo "--- ----- --------------- ---------------------------- -------------------------" |
@@ -44,7 +44,7 @@ do_cmd() | |||
44 | ezjail_list=`echo -n $* | tr -c '[:alnum:] ' '_'` | 44 | ezjail_list=`echo -n $* | tr -c '[:alnum:] ' '_'` |
45 | ezjail_fromrc="NO" | 45 | ezjail_fromrc="NO" |
46 | else | 46 | else |
47 | ezjail_list=`find -X ${ezjail_prefix}/etc/ezjail/ 2> /dev/null | xargs rcorder | xargs basename -a` | 47 | [ -d ${ezjail_prefix}/etc/ezjail/ ] && cd ${ezjail_prefix}/etc/ezjail/ && ezjail_list=`ls | xargs rcorder` |
48 | echo -n "${message##_}" | 48 | echo -n "${message##_}" |
49 | fi | 49 | fi |
50 | 50 | ||