From cedff49db765ecaa534e124f8f075f69aa0f7db7 Mon Sep 17 00:00:00 2001 From: Mr Chen Date: Fri, 15 Mar 2019 14:52:18 +0800 Subject: [PATCH] =?UTF-8?q?openresty=20=E8=87=AA=E5=90=AF=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- class/core/config_api.py | 4 +++- plugins/openresty/index.py | 1 + plugins/openresty/init.d/nginx.tpl | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/class/core/config_api.py b/class/core/config_api.py index a22e8874c..a418db113 100755 --- a/class/core/config_api.py +++ b/class/core/config_api.py @@ -15,7 +15,9 @@ from flask import request class config_api: - __version = '0.4.2' + # 本版解决自启动问题 + # openresty 自启动 done + __version = '0.5.0' def __init__(self): pass diff --git a/plugins/openresty/index.py b/plugins/openresty/index.py index ed737584c..09557c79d 100755 --- a/plugins/openresty/index.py +++ b/plugins/openresty/index.py @@ -232,6 +232,7 @@ def initdInstall(): initd_bin = getInitDFile() shutil.copyfile(source_bin, initd_bin) public.execShell('chmod +x ' + initd_bin) + public.execShell('chkconfig --add ' + getPluginName()) return 'ok' diff --git a/plugins/openresty/init.d/nginx.tpl b/plugins/openresty/init.d/nginx.tpl index f025e8670..ebc8555a9 100644 --- a/plugins/openresty/init.d/nginx.tpl +++ b/plugins/openresty/init.d/nginx.tpl @@ -2,7 +2,7 @@ # chkconfig: 2345 55 25 # Description: Startup script for nginx webserver on Debian. Place in /etc/init.d and # run 'update-rc.d -f nginx defaults', or use the appropriate command on your -# distro. For CentOS/Redhat run: 'chkconfig --add nginx' +# distro. For CentOS/Redhat run: 'chkconfig --add openresty' ### BEGIN INIT INFO # Provides: nginx