I have been trying to get a Django project to connect to a MySQL database on my local computer using a Dockerfile. I would like to be able to do this so that I can use a container to host a website on AWS, so ideally I would like to use a Dockerfile only (not docker compose) as it makes installing it onto Elastic Beanstalk and Lightsail easy.
I have created a repository on GitHub in the following location: https://github.com/MarkyMark1000/PYTHON_MySQL_Django_Docker
I have tried all kinds of things such as using 'RUN apk update && apk add py3-mysqlclient' or trying to install python mysql connector, but I have no luck at present. If you could let me know what I need to do, I would be very grateful.
Many thanks
Mark