diff --git a/plugins/openresty/index.py b/plugins/openresty/index.py index cbcdb8232..e8a2c6f3e 100755 --- a/plugins/openresty/index.py +++ b/plugins/openresty/index.py @@ -101,7 +101,7 @@ def getInitDTpl(): def getPidFile(): file = getConf() content = mw.readFile(file) - rep = 'pid\s*(.*)' + rep = 'pid\s*(.*);' tmp = re.search(rep, content) return tmp.groups()[0].strip() @@ -306,7 +306,11 @@ def start(): def stop(): - return restyOp('stop') + r = restyOp('stop') + pid_file = getPidFile() + if os.path.exists(pid_file): + os.remove(pid_file) + return r def restart(): diff --git a/scripts/lib.sh b/scripts/lib.sh index 0fb075748..b9dd41c5b 100755 --- a/scripts/lib.sh +++ b/scripts/lib.sh @@ -103,6 +103,8 @@ fi pip3 install --upgrade pip -i $PIPSRC pip3 install --upgrade setuptools -i $PIPSRC + +# --no-cache-dir cd /www/server/mdserver-web && pip3 install -r /www/server/mdserver-web/requirements.txt -i $PIPSRC