我正在尝试将我的 django 应用程序部署到亚马逊的 ec2。我在让我的站点包和中间件在 ec2 服务器上工作时遇到了一些麻烦。我正在为我的 AMI 使用 bitnami djangostack,但我很困惑在服务器上的哪个位置放置我的站点包(如向南注册等)以及在何处放置我的中间件(如分页)。
现在我正在运行服务器并收到以下错误:
Traceback (most recent call last):
File "/opt/bitnami/apps/django/lib/python2.6/site-packages/django/core/servers/basehttp.py", line 283, in run
self.result = application(self.environ, self.start_response)
File "/opt/bitnami/apps/django/lib/python2.6/site-packages/django/contrib/staticfiles/handlers.py", line 68, in __call__
return self.application(environ, start_response)
File "/opt/bitnami/apps/django/lib/python2.6/site-packages/django/core/handlers/wsgi.py", line 250, in __call__
self.load_middleware()
File "/opt/bitnami/apps/django/lib/python2.6/site-packages/django/core/handlers/base.py", line 47, in load_middleware
raise exceptions.ImproperlyConfigured('Error importing middleware %s: "%s"' % (mw_module, e))
ImproperlyConfigured: Error importing middleware pagination.middleware: "No module named pagination.middleware"
您可以在以下链接中看到错误