summaryrefslogtreecommitdiffstats
path: root/GitAutoDeploy.py
diff options
context:
space:
mode:
authorTorben <torben.letorbi@gmail.com>2015-07-07 16:15:05 +0200
committerTorben <torben.letorbi@gmail.com>2015-07-07 16:24:53 +0200
commit195530ee628d676658e7f6981a930d80e01f04a6 (patch)
tree4162347167dfd6b32d41440b2b8073941ecedc80 /GitAutoDeploy.py
parentb002375aa175d289d00a6c1343edf34eba766ee2 (diff)
downloadGit-Auto-Deploy-195530ee628d676658e7f6981a930d80e01f04a6.zip
Git-Auto-Deploy-195530ee628d676658e7f6981a930d80e01f04a6.tar.gz
Git-Auto-Deploy-195530ee628d676658e7f6981a930d80e01f04a6.tar.bz2
Make HTTP server listen only on localhost by default; Add config option to change listen host
Diffstat (limited to 'GitAutoDeploy.py')
-rwxr-xr-xGitAutoDeploy.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/GitAutoDeploy.py b/GitAutoDeploy.py
index 5aaebae..56c75a1 100755
--- a/GitAutoDeploy.py
+++ b/GitAutoDeploy.py
@@ -199,7 +199,9 @@ class GitAutoDeployMain:
print 'Github & Gitlab Autodeploy Service v 0.1 started in daemon mode'
try:
- self.server = HTTPServer(('', GitAutoDeploy.getConfig()['port']), GitAutoDeploy)
+ self.server = HTTPServer((GitAutoDeploy.getConfig()['host'], GitAutoDeploy.getConfig()['port']), GitAutoDeploy)
+ sa = self.server.socket.getsockname()
+ print "Listeing on", sa[0], "port", sa[1]
self.server.serve_forever()
except socket.error, e:
if(not GitAutoDeploy.quiet and not GitAutoDeploy.daemon):