From 20b6279c4c07225e00338b123dddabe123aa2676 Mon Sep 17 00:00:00 2001 From: "bt.cn" <287962566@qq.com> Date: Sat, 21 Dec 2019 16:39:36 +0800 Subject: [PATCH] 7.1.15-2 --- runconfig.py | 45 --------------------------------------------- runserver.py | 17 ----------------- 2 files changed, 62 deletions(-) delete mode 100644 runconfig.py delete mode 100644 runserver.py diff --git a/runconfig.py b/runconfig.py deleted file mode 100644 index d5b6f1ad..00000000 --- a/runconfig.py +++ /dev/null @@ -1,45 +0,0 @@ -import os -f = open('data/port.pl','r') -bt_port = f.read() -f.close() -if bt_port: - bt_port.strip() -else: - bt_port = 8888 -bind = [] -if os.path.exists('data/ipv6.pl'): - bind.append('[0:0:0:0:0:0:0:0]:%s' % bt_port) -else: - bind.append('0.0.0.0:%s' % bt_port) - -w_num = 'data/workers.pl' -workers = 1 -if os.path.exists(w_num): - f = open(w_num,'r') - w_str = f.read() - f.close() - if w_str: - workers = int(w_str.strip()) - -threads = 3 -backlog = 512 -daemon = True -timeout = 7200 -keepalive = 60 -debug = os.path.exists('data/debug.pl') -reload = debug -preload_app = not debug -worker_class = 'geventwebsocket.gunicorn.workers.GeventWebSocketWorker' -chdir = '/www/server/panel' -capture_output = True -graceful_timeout=0 -loglevel = 'info' -if debug: loglevel = 'debug' -errorlog = chdir + '/logs/error.log' -accesslog = chdir + '/logs/error.log' -pidfile = chdir + '/logs/panel.pid' -if os.path.exists(chdir + '/data/ssl.pl'): - certfile = 'ssl/certificate.pem' - keyfile = 'ssl/privateKey.pem' - ciphers = 'TLSv1 TLSv1.1 TLSv1.2' - ssl_version = 2 \ No newline at end of file diff --git a/runserver.py b/runserver.py deleted file mode 100644 index cf5be794..00000000 --- a/runserver.py +++ /dev/null @@ -1,17 +0,0 @@ -#coding: utf-8 -# +------------------------------------------------------------------- -# | 宝塔Linux面板 -# +------------------------------------------------------------------- -# | Copyright (c) 2015-2099 宝塔软件(http://bt.cn) All rights reserved. -# +------------------------------------------------------------------- -# | Author: 黄文良 <287962566@qq.com> -# +------------------------------------------------------------------- -from os import environ -from BTPanel import app,sys - -if __name__ == '__main__': - f = open('data/port.pl') - PORT = int(f.read()) - HOST = '0.0.0.0' - f.close() - app.run(host=HOST,port=PORT)