diff --git a/plugins/openresty/install.sh b/plugins/openresty/install.sh index 64b57ce45..c2524650c 100755 --- a/plugins/openresty/install.sh +++ b/plugins/openresty/install.sh @@ -16,11 +16,10 @@ install_tmp=${rootPath}/tmp/mw_install.pl openrestyDir=${serverPath}/source/openresty if id www &> /dev/null ;then - echo "www UID is `id -u www`" - echo "www Shell is `grep "^www:" /etc/passwd |cut -d':' -f7 `" + echo "www uid is `id -u www`" + echo "www shell is `grep "^www:" /etc/passwd |cut -d':' -f7 `" else groupadd www - # useradd -g www -s /sbin/nologin www useradd -g www -s /bin/bash www fi diff --git a/plugins/rsyncd/install.sh b/plugins/rsyncd/install.sh index 4b64e15ff..e75c1870e 100755 --- a/plugins/rsyncd/install.sh +++ b/plugins/rsyncd/install.sh @@ -16,6 +16,14 @@ bash ${rootPath}/scripts/getos.sh OSNAME=`cat ${rootPath}/data/osname.pl` +if id www &> /dev/null ;then + echo "www uid is `id -u www`" + echo "www shell is `grep "^www:" /etc/passwd |cut -d':' -f7 `" +else + groupadd www + useradd -g www -s /bin/bash www +fi + echo $OSNAME install_tmp=${rootPath}/tmp/mw_install.pl Install_rsyncd() diff --git a/plugins/rsyncd/js/rsyncd.js b/plugins/rsyncd/js/rsyncd.js index d99120093..3e460cbfc 100755 --- a/plugins/rsyncd/js/rsyncd.js +++ b/plugins/rsyncd/js/rsyncd.js @@ -1,18 +1,8 @@ -function str2Obj(str){ - var data = {}; - kv = str.split('&'); - for(i in kv){ - v = kv[i].split('='); - data[v[0]] = v[1]; - } - return data; -} - function rsPost(method,args,callback, title){ var _args = null; if (typeof(args) == 'string'){ - _args = JSON.stringify(str2Obj(args)); + _args = JSON.stringify(toArrayObject(args)); } else { _args = JSON.stringify(args); }