Hi there I would like to run my flask app in a container but I got stucked caused of a third party module. (I am using PyCharm)
This is my docker file:
FROM python:3-alpineMAINTAINER fooCOPY app /appWORKDIR /appRUN pip install -r requirements.txtCMD ["python3", "gateway.py"]
I run the container by this command:
docker run --name mei_converter -p 5000:5000 mei_converter:latest
And receives this:
ModuleNotFoundError: No module named 'verovio'
I already fixed the dependencies in order to run it on my local machine
Terminal: python3 gateway.py['/usr/local/lib/python3.7/site-packages',
'/Users/max/PycharmProjects/flaskmicroservice/app',
'/usr/local/Cellar/python/3.7.4/Frameworks/Python.framework/Versions/3.7/lib/python37.zip',
'/usr/local/Cellar/python/3.7.4/Frameworks/Python.framework/Versions/3.7/lib/python3.7',
'/usr/local/Cellar/python/3.7.4/Frameworks/Python.framework/Versions/3.7/lib/python3.7/lib-
dynload', '/Users/max/Library/Python/3.7/lib/python/site-packages',
'/usr/local/lib/python3.7/site-packages', '/usr/local/lib/python3.7/site-packages/verovio-
2.0.0-py3.7-macosx-10.13-x86_64.egg']
* Serving Flask app "gateway" (lazy loading)
* Environment: production
WARNING: This is a development server. Do not use it in a production deployment.
Use a production WSGI server instead.
* Debug mode: off
* Running on http://0.0.0.0:5000/ (Press CTRL+C to quit)
This works well
I also checked the project interpreter in PyCharm and found the package as installed.
Maybe some information about this third party package could help: It is a converter for music-encoding from these guys https://www.verovio.org/python.xhtml and not "native python" (SWIG is necessary) By the way.. I come from the java world and have in fact zero experience with python. I am using this flask app as an microservice for my spring boot app. I would be grateful for any help!