[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [bridgedb/master] Add a Resource.putChild() for the robots.txt file so it gets served.



commit 25ea46bf98f915fd12e9c23889ca05bc15df6c90
Author: Isis Lovecruft <isis@xxxxxxxxxxxxxx>
Date:   Mon Oct 14 22:24:15 2013 +0000

    Add a Resource.putChild() for the robots.txt file so it gets served.
---
 lib/bridgedb/HTTPServer.py |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lib/bridgedb/HTTPServer.py b/lib/bridgedb/HTTPServer.py
index ea4dea7..1143675 100644
--- a/lib/bridgedb/HTTPServer.py
+++ b/lib/bridgedb/HTTPServer.py
@@ -246,7 +246,10 @@ def addWebServer(cfg, dist, sched):
     site = None
     httpdist = twisted.web.resource.Resource()
     httpdist.putChild('', WebRoot())
-    httpdist.putChild('assets', static.File(os.path.join(template_root, 'assets/')))
+    httpdist.putChild('robots.txt',
+                      static.File(os.path.join(template_root, 'robots.txt')))
+    httpdist.putChild('assets',
+                      static.File(os.path.join(template_root, 'assets/')))
 
     resource = WebResource(dist, sched, cfg.HTTPS_N_BRIDGES_PER_ANSWER,
                    cfg.HTTP_USE_IP_FROM_FORWARDED_HEADER,



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits