full-stack-fastapi-template
full-stack-fastapi-template copied to clipboard
MySQL integration
Hello!
I have a question about MySQL integration. Right now we can generate a starter pack with PSQL config. How can I change it so my app will use MySQL?
PGAdmin for PostgreSQL database, you can modify it to use PHPMyAdmin and MySQL easily.
Is there any example project with MySQL integration?
Yes, I also need to know how to do this and also in stead of just mysql also with mssql I think this project would benaffit significantly with a little documentation explaining how to wire up other native (not docker) databases. I have tried replacing “engine = create_engine(settings.SQLALCHEMY_DATABASE_URI, pool_pre_ping=True)” With “engine = create_engine("mysql+mysqlconnector://root:[email protected]:3306/motest")”
But this doesn’t allow the stack to start.
Help would be much appreciated.
Yes, I also need to know how to do this and also in stead of just mysql also with mssql I think this project would benaffit significantly with a little documentation explaining how to wire up other native (not docker) databases. I have tried replacing “engine = create_engine(settings.SQLALCHEMY_DATABASE_URI, pool_pre_ping=True)” With “engine = create_engine("mysql+mysqlconnector://root:[email protected]:3306/motest")”
But this doesn’t allow the stack to start.
Help would be much appreciated.
I'm using pymysql and it work well “engine = create_engine("mysql+pymysql://user:passwd@host:prot/dbname")”
May be this repo could help you
@vuongtlt13 @tiangolo I tried installing google-cloud-storage and I couldn't install it using poetry but pip does it in the system but it's not accessible by the docker project
@vuongtlt13 @tiangolo I tried installing google-cloud-storage and I couldn't install it using poetry but pip does it in the system but it's not accessible by the docker project
I ran it successfully after adding RUN bash -c "pip install google-cloud-storage" in backend.dockerfile
and celeryworker.dockerfile
immediately after the project.toml COPY
command