diff --git a/browsermobproxy/server.py b/browsermobproxy/server.py index 04bfcc4..435bdfa 100644 --- a/browsermobproxy/server.py +++ b/browsermobproxy/server.py @@ -81,15 +81,21 @@ def __init__(self, path='browsermob-proxy', options=None): "in path provided: %s" % path) self.path = path - self.host = 'localhost' + self.host = options.get('address', '0.0.0.0') self.port = options.get('port', 8080) + ttl = options.get('ttl', 0) + use_littleproxy = options.get('use-littleproxy', True) self.process = None if platform.system() == 'Darwin': self.command = ['sh'] else: self.command = [] - self.command += [path, '--port=%s' % self.port] + self.command += [path, + '--address=%s' % self.host, + '--port=%s' % self.port, + '--ttl=%s' % ttl, + '--use-littleproxy=%s' % use_littleproxy] def start(self, options=None): """