Skip to content

Commit f8dc0d7

Browse files
committed
Add --wsgi-server option to change the backend WSGI server.
1 parent 965ddd3 commit f8dc0d7

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

backend/pastee/pastee.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -396,6 +396,8 @@ def main():
396396
parser.add_option('--test', dest='test',
397397
action='store_true', default=False,
398398
help='Test mode: created keys will be removed on shutdown')
399+
parser.add_option('--wsgi-server', dest='wsgi_server', default='wsgiref',
400+
help='WSGI server to use with the Bottle framework')
399401

400402
# Parse commandline options.
401403
(options, args) = parser.parse_args()
@@ -443,7 +445,7 @@ def main():
443445
# We're the child. Run the server.
444446
try:
445447
kwargs['port'] += i # ports must be different for children
446-
bottle.run(server='tornado', **kwargs)
448+
bottle.run(server=options.wsgi_server, **kwargs)
447449
except select.error, e:
448450
num, msg = e
449451
if num == 4: # 'Interrupted system call'

0 commit comments

Comments
 (0)