mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
up
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
location /phpfpm_status_{$PHP_VERSION} {
|
||||
location /phpfpm_status_yum{$PHP_VERSION} {
|
||||
fastcgi_pass unix:/var/opt/remi/php{$PHP_VERSION}/run/php-fpm/www.sock;
|
||||
include fastcgi_params;
|
||||
fastcgi_param SCRIPT_FILENAME \$fastcgi_script_name;
|
||||
|
||||
@@ -110,7 +110,7 @@ def contentReplace(content, version):
|
||||
|
||||
|
||||
def makeOpenrestyConf():
|
||||
phpversions = ['00', '74', '80', '81']
|
||||
phpversions = ['74', '80', '81']
|
||||
|
||||
sdir = mw.getServerDir()
|
||||
d_pathinfo = sdir + '/web_conf/php/pathinfo.conf'
|
||||
@@ -209,8 +209,6 @@ def restart(version):
|
||||
|
||||
|
||||
def reload(version):
|
||||
if version == '52':
|
||||
return phpOp(version, 'restart')
|
||||
return phpOp(version, 'reload')
|
||||
|
||||
|
||||
@@ -473,13 +471,13 @@ def getFpmStatus(version):
|
||||
return mw.returnJson(False, 'PHP[' + version + ']未启动!!!')
|
||||
|
||||
try:
|
||||
url = 'http://' + mw.getHostAddr() + '/phpfpm_status_' + version + '?json'
|
||||
url = 'http://' + mw.getHostAddr() + '/phpfpm_status_yum' + version + '?json'
|
||||
result = mw.httpGet(url, 1)
|
||||
data = json.loads(result)
|
||||
fTime = time.localtime(int(data['start time']))
|
||||
data['start time'] = time.strftime('%Y-%m-%d %H:%M:%S', fTime)
|
||||
except Exception as e:
|
||||
url = 'http://127.0.0.1/phpfpm_status_' + version + '?json'
|
||||
url = 'http://127.0.0.1/phpfpm_status_yum' + version + '?json'
|
||||
result = mw.httpGet(url, 1)
|
||||
data = json.loads(result)
|
||||
fTime = time.localtime(int(data['start time']))
|
||||
|
||||
Reference in New Issue
Block a user