Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
webssh
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
郑天保
webssh
Commits
bc1f4997
Commit
bc1f4997
authored
Feb 27, 2018
by
Sheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added debug option
parent
7474fb76
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
main.py
main.py
+3
-2
No files found.
main.py
View file @
bc1f4997
...
...
@@ -16,6 +16,7 @@ from tornado.util import errno_from_exception
define
(
'address'
,
default
=
'127.0.0.1'
,
help
=
'listen address'
)
define
(
'port'
,
default
=
8888
,
help
=
'listen port'
,
type
=
int
)
define
(
'debug'
,
default
=
False
,
help
=
'debug mode'
,
type
=
bool
)
BUF_SIZE
=
1024
...
...
@@ -264,8 +265,7 @@ def main():
'template_path'
:
os
.
path
.
join
(
base_dir
,
'templates'
),
'static_path'
:
os
.
path
.
join
(
base_dir
,
'static'
),
'cookie_secret'
:
uuid
.
uuid1
()
.
hex
,
'xsrf_cookies'
:
True
,
'debug'
:
True
'xsrf_cookies'
:
True
}
handlers
=
[
...
...
@@ -274,6 +274,7 @@ def main():
]
parse_command_line
()
settings
.
update
(
debug
=
options
.
debug
)
app
=
tornado
.
web
.
Application
(
handlers
,
**
settings
)
app
.
listen
(
options
.
port
,
options
.
address
)
logging
.
info
(
'Listening on {}:{}'
.
format
(
options
.
address
,
options
.
port
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment