aws beanstalk не может найти установленный модуль django - PullRequest
0 голосов
/ 26 октября 2018

Я пытаюсь развернуть приложение Django на AWS beanstalk, однако сталкиваюсь с этой ошибкой.

from django.core.wsgi import get_wsgi_application
[Fri Oct 26 03:22:21.523128 2018] [:error] [pid 4511] [remote 127.0.0.1:2336] ModuleNotFoundError: No module named 'django'
[Fri Oct 26 03:22:22.526577 2018] [:error] [pid 4511] [remote 127.0.0.1:2336] mod_wsgi (pid=4511): Target WSGI script '/opt/python/current/app/adminsite/wsgi.py' cannot be loaded as Python module.

Далее в файле журнала показано, что django был успешно установлен.

[2018-10-26T03:41:56.170Z] INFO  [6032]  - [Application update app-61bb-181025_214141@8/AppDeployStage0/AppDeployPreHook/03deploy.py] : Completed activity. Result:
  Requirement already satisfied: django==2.1.2 in /opt/python/run/venv/lib64/python3.6/site-packages (from -r /opt/python/ondeck/app/requirements.txt (line 1))
  Requirement already satisfied: psycopg2==2.7.5 in /opt/python/run/venv/lib64/python3.6/site-packages (from -r /opt/python/ondeck/app/requirements.txt (line 2))
  Requirement already satisfied: pytz==2018.6 in /opt/python/run/venv/lib/python3.6/site-packages (from -r /opt/python/ondeck/app/requirements.txt (line 3))

Что может быть причиной этой проблемы?

...