I am trying to run a django-docker image via gunicorn. However, gunicorn does not find my modules.
I tried to use gunicorn in a venv. (adding CMD exec source venv/bin/activate
in the Dockerfile.) This is also not working.
What am i doing wrong?
Dockerfile
FROM python:3.6.7
MAINTAINER Jasper
ADD . /usr/src/app
WORKDIR /usr/src/app
COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt
EXPOSE 8000
CMD exec gunicorn bomt_project.wsgi:application --preload --bind
0.0.0.0:8000 --workers 3
I expect the server to be running on port 8000. The output however is ModuleNotFoundError: No module named 'widget_tweaks'
Santiago Trujillo