update
This commit is contained in:
parent
072bc19d01
commit
29d3c11a8e
|
|
@ -90,6 +90,14 @@ def initDreplace():
|
|||
public.writeFile(file_bin, content)
|
||||
public.execShell('chmod +x ' + file_bin)
|
||||
|
||||
pureTplConfig = getPluginDir() + "/init.d/pure-config.pl"
|
||||
pureSbinConfig = getServerDir() + "/sbin/pure-config.pl"
|
||||
|
||||
content = public.readFile(pureTplConfig)
|
||||
content = contentReplace(content)
|
||||
public.writeFile(pureSbinConfig, content)
|
||||
public.execShell('chmod +x ' + pureSbinConfig)
|
||||
|
||||
# # config replace
|
||||
# conf_content = public.readFile(getConf())
|
||||
# conf_content = conf_content.replace('{$SERVER_PATH}', service_path)
|
||||
|
|
@ -103,7 +111,7 @@ def start():
|
|||
data = public.execShell(file + ' start')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def stop():
|
||||
|
|
@ -111,7 +119,7 @@ def stop():
|
|||
data = public.execShell(file + ' stop')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def restart():
|
||||
|
|
@ -127,7 +135,7 @@ def reload():
|
|||
data = public.execShell(file + ' reload')
|
||||
if data[1] == '':
|
||||
return 'ok'
|
||||
return 'fail'
|
||||
return data[1]
|
||||
|
||||
|
||||
def initdStatus():
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"title":"pureftp",
|
||||
"title":"PureFtpd",
|
||||
"tip":"soft",
|
||||
"name":"pureftp",
|
||||
"ps":"PureFTPd是一款专注于程序健壮和软件安全的免费FTP服务器软件",
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ my ($conffile, @flg) = @ARGV;
|
|||
|
||||
my $PUREFTPD;
|
||||
-x && ($PUREFTPD=$_, last) for qw(
|
||||
${exec_prefix}/sbin/pure-ftpd
|
||||
{$SERVER_PATH}/pureftp/sbin/pure-ftpd
|
||||
/www/server/pure-ftpd/sbin/pure-ftpd
|
||||
/www/server/pureftpd/sbin/pure-ftpd
|
||||
/www/server/sbin/pure-ftpd
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
### END INIT INFO
|
||||
|
||||
# Pure-FTPd Settings
|
||||
PURE_PERL="{$SERVER_PATH}/pureftp/sbin/pure-ftpd"
|
||||
PURE_PERL="{$SERVER_PATH}/pureftp/sbin/pure-config.pl"
|
||||
PURE_CONF="{$SERVER_PATH}/pureftp/etc/pure-ftpd.conf"
|
||||
PURE_PID="/var/run/pure-ftpd.pid"
|
||||
RETVAL=0
|
||||
|
|
|
|||
Loading…
Reference in New Issue