diff --git a/kalite/distributed/cherrypyserver.py b/kalite/distributed/cherrypyserver.py index da8f247fb2..2075db70f1 100644 --- a/kalite/distributed/cherrypyserver.py +++ b/kalite/distributed/cherrypyserver.py @@ -163,15 +163,6 @@ def start(self): ) cherrypy.tree.mount(static_handler, settings.STATIC_URL) - # Serve the static files - static_handler = cherrypy.tools.staticdir.handler( - section="/", - dir=os.path.split(settings.CONTENT_DATA_PATH)[1], - root=os.path.abspath(os.path.split(settings.CONTENT_DATA_PATH)[0]), - content_types=WELL_KNOWN_CONTENT_TYPES, - ) - cherrypy.tree.mount(static_handler, settings.CONTENT_DATA_URL) - # Serve the static admin media. From django's internal (django.core.servers.basehttp) admin_static_dir = os.path.join(django.__path__[0], 'contrib', 'admin', 'static') admin_static_handler = cherrypy.tools.staticdir.handler( diff --git a/kalite/distributed/middleware.py b/kalite/distributed/middleware.py index b220513a27..0916fcac7c 100644 --- a/kalite/distributed/middleware.py +++ b/kalite/distributed/middleware.py @@ -22,7 +22,6 @@ def process_request(self, request): not request.path.startswith("/api/") and not request.path.startswith("/securesync/api/user/status") and not request.path.startswith("/securesync/api/user/login") and - not request.path.startswith(settings.CONTENT_DATA_URL) and not request.path.startswith(settings.STATIC_URL) and not request.GET.get('login', '') == 'True' ): diff --git a/kalite/distributed/urls.py b/kalite/distributed/urls.py index c50cb59d21..ede060c8b9 100644 --- a/kalite/distributed/urls.py +++ b/kalite/distributed/urls.py @@ -47,9 +47,6 @@ url(r'^%s(?P.*)$' % settings.CONTENT_URL[1:], 'django.views.static.serve', { 'document_root': settings.CONTENT_ROOT, }), - url(r'^%s(?P.*)$' % settings.CONTENT_DATA_URL[1:], 'django.views.static.serve', { - 'document_root': settings.CONTENT_DATA_PATH, - }), url(r'^%s(?P.*)$' % settings.MEDIA_URL[1:], 'django.views.static.serve', { 'document_root': settings.MEDIA_ROOT, }), diff --git a/kalite/settings/base.py b/kalite/settings/base.py index 9f12f58dc6..3a777bae21 100644 --- a/kalite/settings/base.py +++ b/kalite/settings/base.py @@ -210,8 +210,6 @@ CONTENT_DATA_PATH = getattr(local_settings, "CONTENT_DATA_PATH", _data_path_channels) -CONTENT_DATA_URL = getattr(local_settings, "CONTENT_DATA_URL", "/data/") - ################################################### # USER DATA ################################################### diff --git a/kalite/topic_tools/settings.py b/kalite/topic_tools/settings.py index c40d2260c2..f8600aa1dd 100644 --- a/kalite/topic_tools/settings.py +++ b/kalite/topic_tools/settings.py @@ -20,8 +20,6 @@ CHANNEL = getattr(settings, "CHANNEL", "khan") -CHANNEL_DATA_PATH = os.path.join(settings.CONTENT_DATA_PATH, CHANNEL) - KHAN_EXERCISES_DIRPATH = os.path.join(settings.STATIC_ROOT, "js", "distributed", "perseus", "ke") TOPIC_RECOMMENDATION_DEPTH = 3