expose file descriptor on command line

This commit is contained in:
Sean Mc Allister 2016-07-13 14:09:14 +02:00
parent 0e1bce1714
commit 89686f9034

View File

@ -41,6 +41,13 @@ class CommandLineInterface(object):
help='Bind to a UNIX socket rather than a TCP host/port',
default=None,
)
self.parser.add_argument(
'--fd',
type=int,
dest='file_descriptor',
help='Bind to a file descriptor rather than a TCP host/port or named unix socket',
default=None,
)
self.parser.add_argument(
'-v',
'--verbosity',
@ -133,6 +140,7 @@ class CommandLineInterface(object):
host=args.host,
port=args.port,
unix_socket=args.unix_socket,
file_descriptor=args.file_descriptor,
http_timeout=args.http_timeout,
ping_interval=args.ping_interval,
action_logger=AccessLogGenerator(access_log_stream) if access_log_stream else None,