hxp
4 天以前 388823edfe6308cba6f76ca6dc4f20022c5cb2be
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/usr/bin/python
# -*- coding: GBK -*-
#
##@package
#
# @todo: Àñ°ü¿¨ÖÐÐÄ
#
# @author: Alee
# @date 2018-6-5 ÏÂÎç04:18:14
# @version 1.0
#
#    
#ÐèÒª°²×°µÚÈý·½¿â
#waitress-1.1.0.tar.gz
#requests-2.18.4.tar.gz
#---------------------------------------------------------------------
import webapp
from bottle import run
from lib import mylog
import time
import os
import datetime
from lib import ReadConfig
 
Def_Debug = ReadConfig.ReadConfig(os.getcwd() + "\\config.ini").GetValue("Coupon", "IsDebug")
 
#center.secondworld.net.cn
def main():
    time.sleep(1) 
    os.system("title Coupon-%s"%datetime.datetime.today())
    mylog.InitLog(r"C:/ServerLog", "Coupon.txt", False, Def_Debug)
    
    
    CenterPort = int(ReadConfig.ReadConfig(os.getcwd() + "\\config.ini").GetValue("Coupon", "CenterPort"))
    
    run(host='0.0.0.0', port=CenterPort, app=webapp.myapp, server='waitress')
    return
 
if __name__ == '__main__':
    main()