mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
u
This commit is contained in:
@@ -3,20 +3,16 @@
|
||||
import sys
|
||||
import io
|
||||
import os
|
||||
import time
|
||||
|
||||
from datetime import timedelta
|
||||
|
||||
sys.path.append("/class/core/")
|
||||
sys.path.append("/class/core")
|
||||
reload(sys)
|
||||
sys.setdefaultencoding('utf8')
|
||||
|
||||
import route
|
||||
from flask import Flask
|
||||
import config
|
||||
|
||||
|
||||
app = Flask(__name__)
|
||||
app.debug = True
|
||||
app = config.config().makeApp(__name__)
|
||||
|
||||
|
||||
DEFAULT_MODULES = (
|
||||
@@ -35,13 +31,6 @@ DEFAULT_MODULES = (
|
||||
)
|
||||
|
||||
|
||||
# print "time.time(): %f " % time.time()
|
||||
app.config.version = "0.0.1" + str(time.time())
|
||||
|
||||
app.config['SECRET_KEY'] = os.urandom(24)
|
||||
app.config['PERMANENT_SESSION_LIFETIME'] = timedelta(days=7)
|
||||
|
||||
|
||||
def setting_modules(app, modules):
|
||||
for module, url_prefix in modules:
|
||||
app.register_blueprint(module, url_prefix=url_prefix)
|
||||
|
||||
Reference in New Issue
Block a user