This commit is contained in:
Mr Chen
2019-01-02 18:27:00 +08:00
parent 32a2acf61b
commit 0f4a16ace6
4 changed files with 14 additions and 6 deletions
+11 -3
View File
@@ -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 -1
View File
@@ -1,5 +1,5 @@
{
"title":"pureftp",
"title":"PureFtpd",
"tip":"soft",
"name":"pureftp",
"ps":"PureFTPd是一款专注于程序健壮和软件安全的免费FTP服务器软件",
+1 -1
View File
@@ -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
+1 -1
View File
@@ -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