diff options
-rwxr-xr-x | ezjail.sh | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -45,13 +45,14 @@ do_cmd() | |||
45 | ezjail_list=`echo -n $* | tr -c "[:alnum:] " _` | 45 | ezjail_list=`echo -n $* | tr -c "[:alnum:] " _` |
46 | ezjail_fromrc="NO" | 46 | ezjail_fromrc="NO" |
47 | else | 47 | else |
48 | ezjail_list=${ezjail_list:-`ls ${ezjail_prefix}/etc/ezjail/`} | 48 | ezjail_list=${ezjail_list:-`rcorder ${ezjail_prefix}/etc/ezjail/*`} |
49 | ezjail_list=`basename -a ${ezjail_list}` | ||
49 | echo -n "${message##_}" | 50 | echo -n "${message##_}" |
50 | fi | 51 | fi |
51 | 52 | ||
52 | for ezjail in ${ezjail_list}; do | 53 | for ezjail in ${ezjail_list}; do |
53 | # If jail is temporary disabled (dot in name), skip it | 54 | # If jail is temporary disabled (dot in name), skip it |
54 | [ ${ezjail%.*} = ${ezjail} ] || continue | 55 | [ ${ezjail%.*} != ${ezjail} ] && continue |
55 | 56 | ||
56 | # Check for jails config | 57 | # Check for jails config |
57 | [ ! -r ${ezjail_prefix}/etc/ezjail/${ezjail} ] && echo " Warning: Jail ${ezjail} not found." && continue | 58 | [ ! -r ${ezjail_prefix}/etc/ezjail/${ezjail} ] && echo " Warning: Jail ${ezjail} not found." && continue |