Я использую Docker для запуска моего приложения, которое импортирует django. Я хочу сделать это в моем git хранилище. Мой Dockerfile выглядит как
FROM python:3
WORKDIR /configurator
CMD virtualenv -p python3.8 venv
CMD . venv/bin/activate
CMD pip install -U setuptools pip
CMD pip install django
COPY . /configurator/
CMD cd cconfigurator/
ENTRYPOINT /configurator/cconfigurator/manage.py runserver 8000
И я вижу ошибку:
docker run configurator
Traceback (most recent call last):
File "/configurator/cconfigurator/manage.py", line 10, in main
from django.core.management import execute_from_command_line
ModuleNotFoundError: No module named 'django'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/configurator/cconfigurator/manage.py", line 21, in <module>
main()
File "/configurator/cconfigurator/manage.py", line 12, in main
raise ImportError(
ImportError: Couldn't import Django. Are you sure it's installed and available on your PYTHONPATH environment variable? Did you forget to activate a virtual environment?
Что я делаю не так?