From c0c7cbcdc947b4ec1adfb644aa1ea69d6e9145de Mon Sep 17 00:00:00 2001
From: Friedrich Gonzalez <friedrichg@gmail.com>
Date: Mon, 1 Aug 2011 23:02:24 +0200
Subject: [PATCH] modified: deluge/ui/web/server.py
0001-modified-deluge-ui-web-server.py.patch
---
deluge/ui/web/server.py | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/deluge/ui/web/server.py b/deluge/ui/web/server.py
index 072de51..af3899e 100644
a
|
b
|
|
80 | 80 | |
81 | 81 | # Server Settings |
82 | 82 | "base": "/", |
| 83 | "interface": "0.0.0.0", |
83 | 84 | "port": 8112, |
84 | 85 | "https": False, |
85 | 86 | "pkey": "ssl/daemon.pkey", |
… |
… |
def __init__(self):
|
607 | 608 | self.socket = None |
608 | 609 | self.top_level = TopLevel() |
609 | 610 | self.site = server.Site(self.top_level) |
| 611 | self.interface = self.config["interface"] |
610 | 612 | self.port = self.config["port"] |
611 | 613 | self.https = self.config["https"] |
612 | 614 | self.pkey = self.config["pkey"] |
… |
… |
def start(self, start_reactor=True):
|
649 | 651 | reactor.run() |
650 | 652 | |
651 | 653 | def start_normal(self): |
652 | | self.socket = reactor.listenTCP(self.port, self.site) |
653 | | log.info("serving on %s:%s view at http://127.0.0.1:%s", "0.0.0.0", |
654 | | self.port, self.port) |
| 654 | self.socket = reactor.listenTCP(self.port, self.site, interface=self.interface) |
| 655 | log.info("serving on %s:%s view at http://%s:%s", self.interface, |
| 656 | self.port, self.interface, self.port) |
655 | 657 | |
656 | 658 | def start_ssl(self): |
657 | 659 | check_ssl_keys() |
658 | | self.socket = reactor.listenSSL(self.port, self.site, ServerContextFactory()) |
659 | | log.info("serving on %s:%s view at https://127.0.0.1:%s", "0.0.0.0", |
660 | | self.port, self.port) |
| 660 | self.socket = reactor.listenSSL(self.port, self.site, ServerContextFactory(), interface=self.interface) |
| 661 | log.info("serving on %s:%s view at https://%s:%s", self.interface, |
| 662 | self.port, self.interface, self.port) |
661 | 663 | |
662 | 664 | def stop(self): |
663 | 665 | log.info("Shutting down webserver") |